celenity/Phoenix
8
198
Fork
You've already forked Phoenix
18

rebuild .zip files in nix build #270

Merged
celenity merged 2 commits from andromeda-fp/Phoenix:dev into dev 2026年04月26日 21:10:21 +02:00
Contributor
Copy link

this fixes the nix build on x86_64-linux by removing and regenerating the .zip file. it certaintly doesn't work on nix-darwin but I don't have a device to test it on. I don't think this changes any of the Phoenix functionality.

this fixes the nix build on x86_64-linux by removing and regenerating the .zip file. it certaintly doesn't work on nix-darwin but I don't have a device to test it on. I don't think this changes any of the Phoenix functionality.
celenity requested changes 2026年04月20日 00:40:46 +02:00
Dismissed
celenity left a comment
Copy link

Thank you for submitting this!

I don't think a patch is the best solution here. What do you think about modifying gen-archive.sh directly and leveraging the PHOENIX_NIX environment variable instead? So, for example, maybe we could use something like this?:

if [ "${PHOENIX_NIX}" == 1 ]; then
 readonly PHOENIX_ZIP='zip -r'
else
 readonly PHOENIX_ZIP='zip -r -FS'
fi

Curious to hear your thoughts.

Thank you for submitting this! I don't think a patch is the best solution here. What do you think about modifying `gen-archive.sh` directly and leveraging the `PHOENIX_NIX` environment variable instead? So, for example, maybe we could use something like this?: ```sh if [ "${PHOENIX_NIX}" == 1 ]; then readonly PHOENIX_ZIP='zip -r' else readonly PHOENIX_ZIP='zip -r -FS' fi ``` Curious to hear your thoughts.
Author
Contributor
Copy link

that is a more elegant way of doing it, I agree. The reason to rm the zip file is that otherwise the following error gets thrown, whether with or without the -FS flag; afaik zip doesn't have any --overwrite sort of flag.

phoenix> Creating /build/qvz672gq8ldzzvb2k5w3bcnbyi8a3jmc-source/archives/phoenix-linux.zip...
phoenix> + zip -r /build/qvz672gq8ldzzvb2k5w3bcnbyi8a3jmc-source/archives/phoenix-linux.zip COPYING.txt README.md assets configs defaults etc phoenix.cfg policies resources unused userjs -x 'unused/*'
phoenix> 	zip warning: missing end signature--probably not a zip file (did you
phoenix> 	zip warning: remember to use binary mode when you transferred it?)
phoenix> 	zip warning: (if you are trying to read a damaged archive try -F)
phoenix>
phoenix> zip error: Zip file structure invalid (/build/qvz672gq8ldzzvb2k5w3bcnbyi8a3jmc-source/archives/phoenix-linux.zip)
that is a more elegant way of doing it, I agree. The reason to `rm` the zip file is that otherwise the following error gets thrown, whether with or without the `-FS` flag; afaik `zip` doesn't have any `--overwrite` sort of flag. ``` phoenix> Creating /build/qvz672gq8ldzzvb2k5w3bcnbyi8a3jmc-source/archives/phoenix-linux.zip... phoenix> + zip -r /build/qvz672gq8ldzzvb2k5w3bcnbyi8a3jmc-source/archives/phoenix-linux.zip COPYING.txt README.md assets configs defaults etc phoenix.cfg policies resources unused userjs -x 'unused/*' phoenix> zip warning: missing end signature--probably not a zip file (did you phoenix> zip warning: remember to use binary mode when you transferred it?) phoenix> zip warning: (if you are trying to read a damaged archive try -F) phoenix> phoenix> zip error: Zip file structure invalid (/build/qvz672gq8ldzzvb2k5w3bcnbyi8a3jmc-source/archives/phoenix-linux.zip) ```
celenity left a comment
Copy link

LGTM, thank you!

LGTM, thank you!
celenity changed title from (削除) WIP: rebuild .zip files in nix build (削除ここまで) to rebuild .zip files in nix build 2026年04月26日 21:10:01 +02:00
Sign in to join this conversation.
No reviewers
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
celenity/Phoenix!270
Reference in a new issue
celenity/Phoenix
No description provided.
Delete branch "andromeda-fp/Phoenix:dev"

Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?