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 support to overwrite version using VERSIONINGIT_PRETEND_VERSION #76

Closed
wants to merge 2 commits into from

Conversation

basnijholt
Copy link

@basnijholt basnijholt commented Feb 26, 2024

I frequently encountered situations where I need to install a package without having the full version history available. For example when installing a single package from a large monorepo in a Docker image.

This PR adds support to overwrite the version using an environment variable VERSIONINGIT_PRETEND_VERSION, just like setuptools_scm: https://setuptools-scm.readthedocs.io/en/latest/overrides/#pretend-versions.

@jwodder, let me know what you think and then if you are open to this idea we can add docs.

@jwodder
Copy link
Owner

jwodder commented Mar 8, 2024

I appreciate your contribution, but as I said here, using an envvar to set the version for any package being built would result in the version also being overridden for dependencies of that package that also use versioningit & need to be built from source, and that's an inherently broken design that I don't want to implement.

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

Successfully merging this pull request may close these issues.

2 participants