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

Allow arbitrary prefixes for tags #158

Merged
merged 4 commits into from
Jun 26, 2020

Conversation

sideeffffect
Copy link
Contributor

@sideeffffect sideeffffect commented May 25, 2020

This PR builds on top of #62 by @eliaslevy to bring to sbt-dynver the ability to work with arbitrary prefixes for git tags.
This effectively allows a particular sbt configuration to focus only on a subset of all the tags in the repository.
This is useful when working with multiple projects in one git repository (monorepo-like), when for example some of the projects might not even use sbt-dynver or even use sbt or even be written in Scala.

The PR is as minimalistic as possible and is backwards compatible, especially with regards to the behavior of dynverVTagPrefix.

Could you @dwijnand please review this? 🙏

@sideeffffect sideeffffect changed the title [WIP] Multi project new Multi project new May 25, 2020
@sideeffffect sideeffffect changed the title Multi project new [WIP] Multi project new May 25, 2020
@sideeffffect sideeffffect force-pushed the multi-project-new branch 3 times, most recently from be52464 to 1f752bf Compare May 26, 2020 22:26
@sideeffffect sideeffffect changed the title [WIP] Multi project new Multi project new May 26, 2020
@sideeffffect sideeffffect changed the title Multi project new Allow arbitrary prefixes for tags, suitable for multi-project setup May 26, 2020
@dwijnand

This comment has been minimized.

@sideeffffect

This comment has been minimized.

@dwijnand

This comment has been minimized.

@dwijnand dwijnand closed this May 27, 2020
@sideeffffect

This comment has been minimized.

@sideeffffect sideeffffect changed the title Allow arbitrary prefixes for tags, suitable for multi-project setup Allow arbitrary prefixes for tags May 28, 2020
@dwijnand

This comment has been minimized.

@dwijnand dwijnand reopened this May 28, 2020
@sideeffffect

This comment has been minimized.

@dwijnand

This comment has been minimized.

@sideeffffect

This comment has been minimized.

@dwijnand

This comment has been minimized.

@sideeffffect

This comment has been minimized.

# Conflicts:
#	src/main/scala/sbtdynver/DynVerPlugin.scala
#	src/test/scala/sbtdynver/RepoStates.scala
@dwijnand dwijnand force-pushed the multi-project-new branch from 6c37494 to 9b3c2ad Compare June 26, 2020 14:31
Highlights:

* Introduce dropPrefix as a replacement for dropV;
* Maintain & fast-fail on incoherence against vTagPrefix;
* Introduce a private GitTag subclass instead of anonymous ones;
* Use pattern quoting for the custom prefix;
* Preserve the semantics of all public API;
* also, changed 2 test cases to run 3 times to help me fix the impl;
@dwijnand dwijnand force-pushed the multi-project-new branch from 9b3c2ad to e28197a Compare June 26, 2020 14:55
Copy link
Member

@dwijnand dwijnand left a comment

Choose a reason for hiding this comment

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

Thank you, @eliaslevy and @sideeffffect. I finally spent today reviewing and working on the enhancement. I've squash down the history and everything's passing CI (something's up with the webhook notifications?). Anyways, this is ready to merge. Thank you for the contribution.

@sideeffffect
Copy link
Contributor Author

Those are great news @dwijnand 🎉
Could you please make a release, so that we can use this new feature?
Thank you once again 😃

@sideeffffect sideeffffect deleted the multi-project-new branch June 27, 2020 13:01
@dwijnand
Copy link
Member

Yep, releasing 4.1.0 first thing Monday, if nothing urgent happens.

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.

3 participants