Skip to content
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

Add pip_compile arg for --override file #128

Open
mattlgy opened this issue Sep 5, 2024 · 0 comments
Open

Add pip_compile arg for --override file #128

mattlgy opened this issue Sep 5, 2024 · 0 comments

Comments

@mattlgy
Copy link

mattlgy commented Sep 5, 2024

To provide an overrides file I have to do something like this:

pip_compile(
    name = "generate_requirements_txt",
    requirements_in = "//:requirements.in",
    requirements_txt = "//:requirements.txt",
    data = ["//:overrides.txt"],
    args = [
        // preserving the defaults, but won't stay up-to-date if they change.
        "--generate-hashes",
        "--emit-index-url",
        "--no-strip-extras",
        "--override=overrides.txt"
    ],
)

I think the following API would be a bit more succinct:

pip_compile(
    name = "generate_requirements_txt",
    requirements_in = "//:requirements.in",
    requirements_txt = "//:requirements.txt",
    overrides = "//:overrides.txt",
)

I'm happy to implement this, if it's a good idea.

@mattlgy mattlgy changed the title Provide pip_compile arg for --override Add pip_compile arg for --override file Sep 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant