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 option to allow only overwriting development releases #379

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

sparkyb
Copy link

@sparkyb sparkyb commented Feb 19, 2021

I like the security of not allowing packages with the same version to be overwritten if I forget to bump the version number. However, I'd like to have an automated build job that publishes a development release any time I push to my development branch. Rather than have to remember to edit the version with every commit I push, I want this automated build to automatically add a .dev0 suffix to make sure it is publishing dev releases. I don't want it to have to determine the highest dev version number to increment and I don't mind overwriting these. I could just turn --overwrite on, but I thought that this was a reasonable use case to have an option that only allowed overwriting of dev releases. So I added a --overwrite-dev option that does that.

Internally, it writes to the same config option, so now the option can have 3 possible values: False (no overwrite), True (overwrite any package), "dev" (overwrite only dev releases). I'd be happy to switch it to a real enum if you'd prefer.

@mplanchard
Copy link
Contributor

Thanks for this PR! Just FYI I'm extremely busy right now w/work and a few things that have come up outside of work, so it will be probably a couple of weeks before I can get back to reviewing PRs. I will get to them as soon as possible!

With --overwrite-dev the server will only allow overwriting packages whose
version has a .devN component.
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