-
Notifications
You must be signed in to change notification settings - Fork 3
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
feat: Adding self-extracting file as an optional feature #31
Conversation
One of the biggest use-cases for us for pixi-pack is the ability to build up archives on Linux for foreign targets, like Windows and to extract it there. Having a self-extracting archive there would be probably the most useful scenario. Your prepended shell script will only work for Unix systems, right? Also after taking a (brief) look it appears that the extraction script is expecting a existing conda or micromamba executable on PATH. I think in these scenarios it's already an attractive option to manually extract the archive and create the environment using the included lockfiles. I think it would be very useful, if we could prepend a standalone extraction tool, that does not require any system tools to be available on the system. |
@0xbe7a Also, in regards to the extraction tool used in the script, fair enough. |
The part that involves extracting and linking the packages is highly non-trivial and probably not really feasible with a bash script. Instead, we should try using Additionally, upon reviewing your pull request again, please note that |
Sounds good. Also, in regards to the |
Apologies for the delay. Got busy with school work. |
I think it would be better for reproducibility if we always unpack the same way, i.e. always use |
Could you fix the merge conflicts as well? |
Done. |
…nto selfexec_support
…nto selfexec_support
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.
Really nice @prsabahrami! Thanks for persevering, looking forward to using this feature 🤩
note: tests are failing because it tries to download pixi-pack 0.3.0 in the create-executable tests which is not yet released
Motivation
Closes #4
Changes
Similar to
conda-constructor
, I have added a header.sh file. After the environment has been packed and archived, that archive is appended onto header.sh which later extracts it when it runs.Packing an environment
Unpacking an environment
either directly run the .sh file created
You can use below flags
or you can directly use
I will try to add better tests and error handling in the upcoming days. Meanwhile, let me know if you have any recommendations.