Closed levitsky closed 2 years ago
Hi! Could you test if prepending eval
to $PRE_BUILD_COMMAND fixes the escaping issue?
This https://github.com/RalfG/python-wheels-manylinux-build/blob/5f2c4babb342e922d0bdf5b8a7c636487b706211/entrypoint.sh#L23 would become
eval $PRE_BUILD_COMMAND || { echo "Pre-build command failed."; exit 1; }
Hi @RalfG! Thank you for the suggestion!
I'm not sure what would be the easiest way to actually test a development version of your Github Action. Locally, in a termimnal, this works fine:
$ c="do stuff && cd new_dir"
$ eval $c || { echo "Pre-build command failed."; exit 1; }
However, I'm not sure how to test the whole edited workflow. I noticed that on Github, these things are tokenized weirdly upon logging, but I'm not sure if it's relevant:
Just to add, it looks like I have a similar problem trying to install Rust in order to build a Pyo3 based extension curl https://sh.rustup.rs -sSf | sh -s -- -y && export PATH="$HOME/.cargo/bin:$PATH"
I am going to try putting those in a script and sourcing instead but if you have any other solution i'd love to hear about it.
I would similarly like to set environment variables after the exit of my pre-build command (like PATH). Might a solution here to be to optionally (?) source the file, rather than executing it?
Now implemented in v0.4.0 https://github.com/RalfG/python-wheels-manylinux-build/releases/tag/v0.4.0
Hi!
In my use case I want to switch to the build directory which is created by running
PRE_BUILD_COMMAND
. I cannot do that by specifyingPACKAGE_PATH
becausecd
is attempted before thePRE_BUILD_COMMAND
.I tried to cheat by supplying
do stuff && cd new_dir
ordo stuff; cd new_dir
asPRE_BUILD_COMMAND
, but it is escaped, so that doesn't work. Doing acd
in a script would be of no use either.Is there a way to achieve what I need?
P.S. I also looked at changing the
PIP_WHEEL_ARGS
to specify the actual location of my setup.py (because it is an arg forpip wheel
) but.
is added to thepip wheel
command anyway, so it doesn't help me either. IfPIP_WHEEL_ARGS
would replace all of the standard args, including.
, that would help me.