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

Actions: use commit graph for version comparisons #286

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

ethanent
Copy link
Contributor

@ethanent ethanent commented Sep 2, 2022

Convert tags and branches to commit hash, then, to compare, BFS graph until match found if the comparison operator isn't equals.

Notes about error handling:

  • Require rules are skipped on error as before (eg. if version comparison ">= v3.0.1" used but there is no v3.0.1 tag)
  • Deny rules are skipped on error as before (eg. if version comparison "<= v2.3.0" used but there is no v2.3.0 tag)
    • "v2.3.0" isn't considered equivalent to "2.3.0" beginning with this PR because tags are mapped to commits for comparison

@ethanent
Copy link
Contributor Author

ethanent commented Sep 2, 2022

Add option qualifyUntaggedCommits for allow / require rule?

Signed-off-by: Ethan Davis <etdavis@google.com>
@ethanent ethanent marked this pull request as ready for review September 7, 2022 21:53
Signed-off-by: Ethan Davis <etdavis@google.com>
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.

None yet

1 participant