From 686fb986afc7bf97e7d12cd6acd1df30da13171a Mon Sep 17 00:00:00 2001 From: Patrick Mowrer Date: Sun, 11 Feb 2018 12:47:37 -0500 Subject: [PATCH 1/2] docs: replace references to `publish` plugin w/ `generateNotes` --- README.md | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 8c90c01..c53d74f 100644 --- a/README.md +++ b/README.md @@ -65,8 +65,6 @@ E.g., `package.json`: } ``` -[Other ways of configuring `branch`.](https://github.com/semantic-release/semantic-release/blob/caribou/docs/usage/configuration.md#configuration.) - #### Advanced Due to limitations in how plugins may be composed, `semantic-release-github-pr` must unfortunately hard-code the [`analyzeCommits` plugin](#analyzecommits) (see discussion [here](https://github.com/semantic-release/semantic-release/issues/550)). @@ -117,7 +115,7 @@ Running `semantic-release-github-pr` is equivalent to running `semantic-release` { "release": { "analyzeCommits": "semantic-release-github-pr", - "publish": "semantic-release-github-pr", + "generateNotes": "semantic-release-github-pr", "verifyConditions": [ "@semantic-release/github", "semantic-release-github-pr" @@ -128,7 +126,7 @@ Running `semantic-release-github-pr` is equivalent to running `semantic-release` #### verifyConditions -Used as a hook for cleaning up previous changelog PR comments made by the `publish` plugin, keeping it from flooding a PR with (eventually stale) changelog comments over time. +Used as a hook for cleaning up previous changelog PR comments made by the `generateNotes` plugin, keeping it from flooding a PR with (eventually stale) changelog comments over time. It's recommended to pair this package's `verifyConditions` with that of [`@semantic-release/github`](https://github.com/semantic-release/github#verifyconditions). @@ -138,6 +136,6 @@ Used as a hook to create a "no release" comment on a matching PR, if `semantic-r See the [`Release config`](#release-config) section for how to configure a custom `analyzeCommits` plugin and/or set options. -#### publish +#### generateNotes Creates a comment on matching PRs with the changelog for the release that would result from merging. From 830d93164ac272dd647d5a44136f842af5c98a44 Mon Sep 17 00:00:00 2001 From: Patrick Mowrer Date: Sun, 11 Feb 2018 12:55:59 -0500 Subject: [PATCH 2/2] fix: `dry-run` is always set, remove use in conditional --- src/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/index.js b/src/index.js index b07f1ee..0f316b0 100644 --- a/src/index.js +++ b/src/index.js @@ -36,7 +36,7 @@ const analyzeCommits = wrapPlugin( const { dryRun, githubRepo, pullRequests } = pluginConfig; const nextRelease = await plugin(pluginConfig, config); - if (!nextRelease && !dryRun) { + if (!nextRelease) { await pullRequests.forEach(async pr => { const { number } = pr; const createChangelogOnPr = createChangelog(pluginConfig, config);