-
Notifications
You must be signed in to change notification settings - Fork 201
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
Next/Canary Support for Gradle #1842
Conversation
plugins/gradle/src/index.ts
Outdated
auto.hooks.afterShipIt.tapPromise(this.name, async ({ dryRun }) => { | ||
if (!this.snapshotRelease || dryRun) { | ||
if (!this.snapshotRelease || dryRun || this.canaryRelease) { |
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 hook receives a context
that will be canary
if it's a canary release. you should be able to remove the class field and just do the check with context
plugins/gradle/src/index.ts
Outdated
@@ -238,8 +242,89 @@ export default class GradleReleasePluginPlugin implements IPlugin { | |||
]); | |||
}); | |||
|
|||
auto.hooks.canary.tapPromise( | |||
this.name, | |||
async ({ dryRun, quiet }) => { |
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 hook receives canaryIdentifier
that should be used to create the canary version
Codecov Report
@@ Coverage Diff @@
## main #1842 +/- ##
==========================================
+ Coverage 80.10% 80.12% +0.02%
==========================================
Files 64 64
Lines 5001 5042 +41
Branches 1155 1171 +16
==========================================
+ Hits 4006 4040 +34
+ Misses 673 671 -2
- Partials 322 331 +9
Continue to review full report at Codecov.
|
🚀 PR was released in |
@@ -103,6 +106,7 @@ export default class GradleReleasePluginPlugin implements IPlugin { | |||
private readonly updateGradleVersion = async ( | |||
version: string, | |||
commitMsg?: string, | |||
commit = true, |
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.
@sentony93 Adding a new param in the middle breaks existing callers. See line #356. This breaks the actual release since it no longer commits the prepared version. You should reorder the new argument to the end to ensure that you don't break existing call-sites.
What Changed
Tap into canary and next hooks in Gradle plugin to handle canary and prerelease
Why
Todo:
Change Type
Indicate the type of change your pull request is:
documentation
patch
minor
major
🐤 Download canary assets:
auto-linux-canary.1842.22803.gz
auto-macos-canary.1842.22803.gz
auto-win.exe-canary.1842.22803.gz
📦 Published PR as canary version:
under canary scope @auto-canary@10.18.4-canary.1842.22803.0
✨ Test out this PR locally via:
npm install @auto-canary/bot-list@10.18.4-canary.1842.22803.0 npm install @auto-canary/auto@10.18.4-canary.1842.22803.0 npm install @auto-canary/core@10.18.4-canary.1842.22803.0 npm install @auto-canary/package-json-utils@10.18.4-canary.1842.22803.0 npm install @auto-canary/all-contributors@10.18.4-canary.1842.22803.0 npm install @auto-canary/brew@10.18.4-canary.1842.22803.0 npm install @auto-canary/chrome@10.18.4-canary.1842.22803.0 npm install @auto-canary/cocoapods@10.18.4-canary.1842.22803.0 npm install @auto-canary/conventional-commits@10.18.4-canary.1842.22803.0 npm install @auto-canary/crates@10.18.4-canary.1842.22803.0 npm install @auto-canary/docker@10.18.4-canary.1842.22803.0 npm install @auto-canary/exec@10.18.4-canary.1842.22803.0 npm install @auto-canary/first-time-contributor@10.18.4-canary.1842.22803.0 npm install @auto-canary/gem@10.18.4-canary.1842.22803.0 npm install @auto-canary/gh-pages@10.18.4-canary.1842.22803.0 npm install @auto-canary/git-tag@10.18.4-canary.1842.22803.0 npm install @auto-canary/gradle@10.18.4-canary.1842.22803.0 npm install @auto-canary/jira@10.18.4-canary.1842.22803.0 npm install @auto-canary/magic-zero@10.18.4-canary.1842.22803.0 npm install @auto-canary/maven@10.18.4-canary.1842.22803.0 npm install @auto-canary/microsoft-teams@10.18.4-canary.1842.22803.0 npm install @auto-canary/npm@10.18.4-canary.1842.22803.0 npm install @auto-canary/omit-commits@10.18.4-canary.1842.22803.0 npm install @auto-canary/omit-release-notes@10.18.4-canary.1842.22803.0 npm install @auto-canary/pr-body-labels@10.18.4-canary.1842.22803.0 npm install @auto-canary/released@10.18.4-canary.1842.22803.0 npm install @auto-canary/s3@10.18.4-canary.1842.22803.0 npm install @auto-canary/slack@10.18.4-canary.1842.22803.0 npm install @auto-canary/twitter@10.18.4-canary.1842.22803.0 npm install @auto-canary/upload-assets@10.18.4-canary.1842.22803.0 npm install @auto-canary/vscode@10.18.4-canary.1842.22803.0 # or yarn add @auto-canary/bot-list@10.18.4-canary.1842.22803.0 yarn add @auto-canary/auto@10.18.4-canary.1842.22803.0 yarn add @auto-canary/core@10.18.4-canary.1842.22803.0 yarn add @auto-canary/package-json-utils@10.18.4-canary.1842.22803.0 yarn add @auto-canary/all-contributors@10.18.4-canary.1842.22803.0 yarn add @auto-canary/brew@10.18.4-canary.1842.22803.0 yarn add @auto-canary/chrome@10.18.4-canary.1842.22803.0 yarn add @auto-canary/cocoapods@10.18.4-canary.1842.22803.0 yarn add @auto-canary/conventional-commits@10.18.4-canary.1842.22803.0 yarn add @auto-canary/crates@10.18.4-canary.1842.22803.0 yarn add @auto-canary/docker@10.18.4-canary.1842.22803.0 yarn add @auto-canary/exec@10.18.4-canary.1842.22803.0 yarn add @auto-canary/first-time-contributor@10.18.4-canary.1842.22803.0 yarn add @auto-canary/gem@10.18.4-canary.1842.22803.0 yarn add @auto-canary/gh-pages@10.18.4-canary.1842.22803.0 yarn add @auto-canary/git-tag@10.18.4-canary.1842.22803.0 yarn add @auto-canary/gradle@10.18.4-canary.1842.22803.0 yarn add @auto-canary/jira@10.18.4-canary.1842.22803.0 yarn add @auto-canary/magic-zero@10.18.4-canary.1842.22803.0 yarn add @auto-canary/maven@10.18.4-canary.1842.22803.0 yarn add @auto-canary/microsoft-teams@10.18.4-canary.1842.22803.0 yarn add @auto-canary/npm@10.18.4-canary.1842.22803.0 yarn add @auto-canary/omit-commits@10.18.4-canary.1842.22803.0 yarn add @auto-canary/omit-release-notes@10.18.4-canary.1842.22803.0 yarn add @auto-canary/pr-body-labels@10.18.4-canary.1842.22803.0 yarn add @auto-canary/released@10.18.4-canary.1842.22803.0 yarn add @auto-canary/s3@10.18.4-canary.1842.22803.0 yarn add @auto-canary/slack@10.18.4-canary.1842.22803.0 yarn add @auto-canary/twitter@10.18.4-canary.1842.22803.0 yarn add @auto-canary/upload-assets@10.18.4-canary.1842.22803.0 yarn add @auto-canary/vscode@10.18.4-canary.1842.22803.0