https://pantsbuild.org/ logo
#general
Title
# general
b

billions-bear-56484

04/02/2022, 2:40 PM
Hi guys, I was wondering if it is possible, to define script arguments in the pex_binary target? Currently my target looks like this and have to pass the arguments manually:
Copy code
pex_binary(
    name="alembic",
    script="alembic",
    dependencies=[
        ":alembic_requirements",
    ],
)
My goal is to have something like this:
Copy code
pex_binary(
    name="makemigrations",
    script="alembic -n accounts revision --autogenerate",
    // or entry_point="alembic -n accounts revision --autogenerate",
    dependencies=[
        ":alembic_requirements",
    ],
)
Thanks and have a great weekend 🎉
e

enough-analyst-54434

04/02/2022, 3:43 PM
@billions-bear-56484 it is not possible today. Pex would need to support this. You could vote up https://github.com/pantsbuild/pex/issues/987 or even try tackling it if you want. I'm happy to help shepherd your work if so.
b

billions-bear-56484

04/02/2022, 3:45 PM
Thanks for your feedback. Will vote up 🙂
5 Views