-
Notifications
You must be signed in to change notification settings - Fork 281
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
Staging for version increment automation #1932
Conversation
Signed-off-by: pgodithi <pgodithi@amazon.com>
Signed-off-by: pgodithi <pgodithi@amazon.com>
Signed-off-by: pgodithi <pgodithi@amazon.com>
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1932 +/- ##
============================================
+ Coverage 61.00% 61.01% +0.01%
- Complexity 3233 3234 +1
============================================
Files 256 256
Lines 18088 18088
Branches 3224 3224
============================================
+ Hits 11035 11037 +2
+ Misses 5470 5467 -3
- Partials 1583 1584 +1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Before we merge this change should have a test to ensure its functionality.
build.gradle
Outdated
@@ -486,3 +486,20 @@ afterEvaluate { | |||
tasks = ['build', 'buildRpm', 'buildDeb'] | |||
} | |||
} | |||
|
|||
// versionIncrement: Task to auto increment to the next development iteration | |||
task versionIncrement { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add a test for this, see example tests in https://github.com/opensearch-project/security/blob/main/.github/workflows/ci.yml#L124
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added @peternied can you please check.
Thank you
Signed-off-by: pgodithi <pgodithi@amazon.com>
.github/workflows/ci.yml
Outdated
@@ -125,6 +125,8 @@ jobs: | |||
|
|||
- run: ./gradlew clean assemble -Dbuild.version_qualifier=${{ env.TEST_QUALIFIER }} && test -s ./build/distributions/opensearch-security-${{ env.SECURITY_PLUGIN_VERSION_ONLY_NUMBER }}-${{ env.TEST_QUALIFIER }}-SNAPSHOT.zip | |||
|
|||
- run: ./gradlew clean versionIncrement -DnewVersion=3.0.0-SNAPSHOT |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This executes the command, but doesn't verify any outcome.
What do you think about adding a execution of the gradle task assemble
, check the artifact is version X, then run the versionIncrement
task, then assemble
and check its version X+1
Signed-off-by: pgodithi <pgodithi@amazon.com>
Renaming to task updateVersion following opensearch-project/opensearch-plugin-template-java#32. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good. I agree with Peter's ask on testing to verify whether this change would work, if it is possible.
@prudhvigodithi Do you need any help with this? |
Hey @peternied I should be pushing the requested change by end of today, just got pulled away from this :) |
Signed-off-by: pgodithi <pgodithi@amazon.com>
Signed-off-by: pgodithi <pgodithi@amazon.com>
Signed-off-by: pgodithi <pgodithi@amazon.com>
Hey @peternied and @DarshitChanpura I have updated the CI workflow running the task |
@davidlago @peternied @DarshitChanpura Can you please review this PR soon? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @prudhvigodithi !
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @prudhvigodithi !
The backport to
To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-2.0 2.0
# Navigate to the new working tree
cd .worktrees/backport-2.0
# Create a new branch
git switch --create backport/backport-1932-to-2.0
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 235d25672139c0663b422c3f7a2354e0250f23b0
# Push it to GitHub
git push --set-upstream origin backport/backport-1932-to-2.0
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-2.0 Then, create a pull request where the |
* Version increment automation Signed-off-by: pgodithi <pgodithi@amazon.com> (cherry picked from commit 235d256)
The backport to
To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-2.1 2.1
# Navigate to the new working tree
cd .worktrees/backport-2.1
# Create a new branch
git switch --create backport/backport-1932-to-2.1
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 235d25672139c0663b422c3f7a2354e0250f23b0
# Push it to GitHub
git push --set-upstream origin backport/backport-1932-to-2.1
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-2.1 Then, create a pull request where the |
* Version increment automation Signed-off-by: pgodithi <pgodithi@amazon.com>
* Version increment automation Signed-off-by: pgodithi <pgodithi@amazon.com>
Hey @peternied I see the following PR is closed #1933, but this change is not backported to 1.x (1.3) branches, can you please take a look? Thank you |
The backport to
To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-1.3 1.3
# Navigate to the new working tree
cd .worktrees/backport-1.3
# Create a new branch
git switch --create backport/backport-1932-to-1.3
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 235d25672139c0663b422c3f7a2354e0250f23b0
# Push it to GitHub
git push --set-upstream origin backport/backport-1932-to-1.3
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-1.3 Then, create a pull request where the |
* Version increment automation Signed-off-by: pgodithi <pgodithi@amazon.com> (cherry picked from commit 235d256)
* Version increment automation Signed-off-by: pgodithi <pgodithi@amazon.com> (cherry picked from commit 235d256)
* Version increment automation Signed-off-by: pgodithi <pgodithi@amazon.com> (cherry picked from commit 235d256)
* Version increment automation Signed-off-by: pgodithi <pgodithi@amazon.com> (cherry picked from commit 235d256)
* Version increment automation Signed-off-by: pgodithi <pgodithi@amazon.com> (cherry picked from commit 235d256)
* Version increment automation Signed-off-by: pgodithi <pgodithi@amazon.com> (cherry picked from commit 235d256)
@prudhvigodithi Could you double check #2029 and make sure it will work as expected? |
* Version increment automation Signed-off-by: pgodithi <pgodithi@amazon.com> (cherry picked from commit 235d256)
* Staging for version increment automation (#1932) Incorporating changes from #1741 Specifically build.gradle changes, see 2744081#diff-49a96e7eea8a94af862798a45174e6ac43eb4f8b4bd40759b5da63ba31ec3ef7 Signed-off-by: pgodithi <pgodithi@amazon.com> Signed-off-by: Peter Nied <petern@amazon.com> Co-authored-by: Prudhvi Godithi <pgodithi@amazon.com> (cherry picked from commit 235d256)
* Version increment automation Signed-off-by: pgodithi <pgodithi@amazon.com> Signed-off-by: Stephen Crawford <steecraw@amazon.com>
Signed-off-by: pgodithi pgodithi@amazon.com
Description
This is the staging PR for to execute workflows that auto raise the version increment PR's
Example: prudhvigodithi#2
Issues Resolved
Part of: opensearch-project/opensearch-build#1375
From solution: opensearch-project/opensearch-build#1375 (comment)
Related issue: #1930
Is this a backport? If so, please add backport PR # and/or commits #
Testing
Example: prudhvigodithi#2
Check List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.