-
Notifications
You must be signed in to change notification settings - Fork 1
idk either #125
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
idk either #125
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -77,6 +77,7 @@ NOTHING_TO_BUILD_APPS = \ | |||||||||||||||||||||||||||||||||||||||||||
| # Apps with special build targets (not in the standard categories above) | ||||||||||||||||||||||||||||||||||||||||||||
| # These apps have dedicated build_<app>_app targets with custom build logic | ||||||||||||||||||||||||||||||||||||||||||||
| SPECIAL_BUILD_APPS = \ | ||||||||||||||||||||||||||||||||||||||||||||
| gdatavaas \ | ||||||||||||||||||||||||||||||||||||||||||||
| notify_push | ||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||
| # App folders to add to shipped.json (makes apps non-removable) | ||||||||||||||||||||||||||||||||||||||||||||
|
|
@@ -263,6 +264,42 @@ $(NOTIFY_PUSH_BINARY): $(NOTIFY_PUSH_DIR)/appinfo/info.xml | |||||||||||||||||||||||||||||||||||||||||||
| chmod +x $@ | ||||||||||||||||||||||||||||||||||||||||||||
| @echo "[i] notify_push binary v$(NOTIFY_PUSH_VERSION) downloaded and verified successfully" | ||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||
| # gdatavaas app target with php-scoper namespace scoping | ||||||||||||||||||||||||||||||||||||||||||||
| # amphp/amp v3 (used by gdata/vaas) conflicts with amphp/amp v2 (used by mail via rubix/ml). | ||||||||||||||||||||||||||||||||||||||||||||
| # php-scoper rewrites vendor namespaces (e.g. Amp\ -> OCA\GDataVaas\Vendor\Amp\) to avoid conflicts. | ||||||||||||||||||||||||||||||||||||||||||||
| GDATAVAAS_DIR = apps-external/gdatavaas | ||||||||||||||||||||||||||||||||||||||||||||
| GDATAVAAS_SCOPED_DIR = $(GDATAVAAS_DIR)/build/scoped | ||||||||||||||||||||||||||||||||||||||||||||
| PHP_SCOPER_PHAR = $(GDATAVAAS_DIR)/build/php-scoper.phar | ||||||||||||||||||||||||||||||||||||||||||||
| PHP_SCOPER_VERSION = 0.18.17 | ||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||
| $(PHP_SCOPER_PHAR): | ||||||||||||||||||||||||||||||||||||||||||||
| @mkdir -p $(dir $(PHP_SCOPER_PHAR)) | ||||||||||||||||||||||||||||||||||||||||||||
| @echo "[i] Downloading php-scoper $(PHP_SCOPER_VERSION) PHAR..." | ||||||||||||||||||||||||||||||||||||||||||||
| @curl -sL -o $(PHP_SCOPER_PHAR) \ | ||||||||||||||||||||||||||||||||||||||||||||
| https://github.com/humbug/php-scoper/releases/download/$(PHP_SCOPER_VERSION)/php-scoper.phar | ||||||||||||||||||||||||||||||||||||||||||||
| @chmod +x $(PHP_SCOPER_PHAR) | ||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+274
to
+280
|
||||||||||||||||||||||||||||||||||||||||||||
| $(PHP_SCOPER_PHAR): | |
| @mkdir -p $(dir $(PHP_SCOPER_PHAR)) | |
| @echo "[i] Downloading php-scoper $(PHP_SCOPER_VERSION) PHAR..." | |
| @curl -sL -o $(PHP_SCOPER_PHAR) \ | |
| https://github.com/humbug/php-scoper/releases/download/$(PHP_SCOPER_VERSION)/php-scoper.phar | |
| @chmod +x $(PHP_SCOPER_PHAR) | |
| # Expected SHA256 checksum for php-scoper $(PHP_SCOPER_VERSION) PHAR. | |
| # Update this value whenever PHP_SCOPER_VERSION is changed. | |
| PHP_SCOPER_SHA256 = 0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef | |
| $(PHP_SCOPER_PHAR): | |
| @mkdir -p $(dir $(PHP_SCOPER_PHAR)) | |
| @echo "[i] Downloading php-scoper $(PHP_SCOPER_VERSION) PHAR..." | |
| @tmp="$@.tmp" ; \ | |
| curl --fail --location --show-error --silent \ | |
| -o "$$tmp" \ | |
| "https://github.com/humbug/php-scoper/releases/download/$(PHP_SCOPER_VERSION)/php-scoper.phar" ; \ | |
| echo "$(PHP_SCOPER_SHA256) $$tmp" | sha256sum -c - ; \ | |
| chmod +x "$$tmp" ; \ | |
| mv "$$tmp" "$@" |
Copilot
AI
Mar 4, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
php-scoper.phar is stored under apps-external/gdatavaas/build/ and is not removed after the build. Since the packaging target zips apps-external/ and doesn’t exclude **/build/**, this will likely ship the PHAR inside the release artifact unintentionally. Consider deleting the PHAR after use or adding an explicit zip exclude for app build tooling directories.
Copilot
AI
Mar 4, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This target mutates the app in-place by moving lib/ and vendor/ out of the way and replacing them with the scoped output, then deletes the backups. That makes the build non-idempotent for local development and leaves the working tree irreversibly modified if a later step fails. Consider keeping the original directories (or backups) until the end, and/or producing the scoped artifact in a separate staging directory that packaging consumes instead of overwriting the sources.
| @rm -rf $(GDATAVAAS_DIR)/lib.orig $(GDATAVAAS_DIR)/vendor.orig $(GDATAVAAS_SCOPED_DIR) | |
| @rm -rf $(GDATAVAAS_SCOPED_DIR) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PHP_SCOPER_VERSIONcan change without forcing a re-download because the output path$(PHP_SCOPER_PHAR)is versionless. This can leave an old php-scoper binary in place while the Makefile claims a newer version. Consider versioning the filename (or using a stamp file tied toPHP_SCOPER_VERSION) so Make reliably fetches the requested version.