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

Fix issues #12

Merged
merged 36 commits into from
Mar 7, 2024
Merged

Conversation

erikbrudzinskis
Copy link
Contributor

Fixes #4

  • The output now has correct branch and version.

Closes #7

  • Adds an additional parameter "checkForUncommittedChanges". If set to true and there are uncommitted changes, then aborts the procedure.

Closes #9

  • Allows to update any old version to SNAPSHOT.

Not entirely sure what's happened there. versions-maven-plugin:set does not seem to assume anything about the branches. It looks like it was trying to update the wrong version (i.e. 0.0.5 -> 0.0.7-SNAPSHOT, when it should have been 0.0.6 -> 0.0.7-SNAPSHOT). It couldn't find it and ignored "set version" altogether. As a result, it didn't work for me on any branch.

Possibly, there was a race condition, and sometimes it worked, sometimes it didn't. I.e. if MavenProject is correctly updated with the correct release version before we attempt to change it to snapshot, then it would work. Or it could have been some changes on Git side?

Anyway, allowing to update any old version seems to do the trick. Tested locally with main and master branches on different projects.

Other

  • Java version is now updated to 11.
  • Dependencies now updated to avoid high-risk vulnerabilities.

@anton-johansson anton-johansson changed the base branch from master to main February 13, 2024 17:05
Copy link
Owner

@anton-johansson anton-johansson left a comment

Choose a reason for hiding this comment

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

Nice work! Some small things, otherwise mergeable. How should we handle the commits? Squash everything into one big commit that closes the three issues?

@anton-johansson
Copy link
Owner

Hmm, the patch command no longer works.

@anton-johansson
Copy link
Owner

I stole your commit that fixes the unit tests and put it in this one instead: #13. Lets get that one merged first, so we get the CI build working.

Erik Brudzinskis and others added 3 commits February 17, 2024 17:58
Remove usage of deprecated methods
Apply minor fixes
Remove usage of deprecated methods
Fix tests by committing all uncommitted changes before execution
Update Java version to 11,update dependencies to avoid high-risk vulnerabilities and add commons-io to dependencies as it is no longer a part of maven-core
Allow preparing snapshot for any previous version to avoid a bug, where snapshot version is not set
Add a check for uncommitted changes. By default, abort version change, if any uncommitted changes are present.
Fix summary output to display correct branch and version
Apply minor fixes
@erikbrudzinskis
Copy link
Contributor Author

erikbrudzinskis commented Feb 17, 2024

I have added the changes to patch - to not create snapshots. And squashed all commits.

You mentioned that patch does not work - it seems to work fine for me, could you give some more info so I can replicate?

Erik Brudzinskis and others added 14 commits March 7, 2024 08:42
Remove usage of deprecated methods
Apply minor fixes
Add profile for artifact signing
Remove usage of deprecated methods
Fix tests by committing all uncommitted changes before execution
Update Java version to 11,update dependencies to avoid high-risk vulnerabilities and add commons-io to dependencies as it is no longer a part of maven-core
Allow preparing snapshot for any previous version to avoid a bug, where snapshot version is not set
Add a check for uncommitted changes. By default, abort version change, if any uncommitted changes are present.
Fix summary output to display correct branch and version
Apply minor fixes
Remove usage of deprecated methods
Apply minor fixes
Remove usage of deprecated methods
Apply minor fixes
Add profile for artifact signing
anton-johansson and others added 12 commits March 7, 2024 12:02
Remove usage of deprecated methods
Fix tests by committing all uncommitted changes before execution
Update Java version to 11,update dependencies to avoid high-risk vulnerabilities and add commons-io to dependencies as it is no longer a part of maven-core
Allow preparing snapshot for any previous version to avoid a bug, where snapshot version is not set
Add a check for uncommitted changes. By default, abort version change, if any uncommitted changes are present.
Fix summary output to display correct branch and version
Apply minor fixes
Remove usage of deprecated methods
Apply minor fixes
Remove usage of deprecated methods
Apply minor fixes
Add profile for artifact signing
Remove usage of deprecated methods
Apply minor fixes
Remove usage of deprecated methods
Apply minor fixes
anton-johansson
anton-johansson previously approved these changes Mar 7, 2024
@erikbrudzinskis erikbrudzinskis dismissed anton-johansson’s stale review March 7, 2024 11:36

The merge-base changed after approval.

@anton-johansson anton-johansson merged commit 6f50055 into anton-johansson:main Mar 7, 2024
1 check passed
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.

Assumes that the default branch is master Abort if uncommitted changes Summary output wrong
2 participants