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

Implement support for key revision.tag=last #25

Merged
merged 10 commits into from
Feb 1, 2022
Merged

Conversation

Grokzen
Copy link
Collaborator

@Grokzen Grokzen commented Jan 24, 2022

Closes #23

Implement support for specifying "revision.tag=latest" key and support for a few helper options that can be used to filter and clean tags to allow for semver to work it's magic. Please see docs for additional examples and usage of all options.

…est and let the tool attempt to parse out all the tags from the git repo and determine what tag should be used and if we need to update. There are additional options to set to this revision.tag=latest feature, see docs for details about each individual option.
@Grokzen Grokzen requested a review from holmboe January 24, 2022 14:32
docs/revision-branch.md Outdated Show resolved Hide resolved
docs/revision-branch.md Outdated Show resolved Hide resolved
docs/revision-branch.md Outdated Show resolved Hide resolved
docs/revision-tag.md Outdated Show resolved Hide resolved
docs/revision-tag.md Outdated Show resolved Hide resolved
docs/revision-tag.md Outdated Show resolved Hide resolved
sgit/core.py Outdated Show resolved Hide resolved
Grokzen and others added 9 commits January 25, 2022 10:29
Co-authored-by: Henrik Holmboe <henrik@dynamist.se>
…e. Add __all__ to exceptions.py and constants.py to make them properly importable with *
…sing, filter, order & select.

- Replace package semver with packaging for better PEP440 support
- Separate out filter, order & select to new methods to declutter update() method
- Impelment unittests for new logics to validate each step and the entire chain works together as expected
- New enums.py file that will be used to define all supported algorithms we have
@Grokzen Grokzen requested a review from holmboe January 31, 2022 12:29
@Grokzen Grokzen changed the title Implement support for key revision.tag=latest Implement support for key revision.tag=last Jan 31, 2022
Copy link
Contributor

@holmboe holmboe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor comment. LGTM.


class SelectionMethods(Enum):
SEMVER = 10
EXACT = 20
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe use LITERAL instead of EXACT? You decide.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I might, but let me think about it and i will push it in a future commit if i change it. I find both options a little bit wonky tbh

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added in this as a idea card in the 1.0.0 project for keeping track of this suggestion

sgit/core.py Show resolved Hide resolved
@Grokzen Grokzen merged commit 103ff58 into master Feb 1, 2022
@Grokzen Grokzen deleted the f/latest-semver-parsing branch February 1, 2022 11:23
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.

Implement support for specifying "latest" on tag block to attempt to resolve it from list of possible tags
2 participants