Repository navigation
Generate root changelog in fixed mode - #1078
Merged
Merged
Conversation
When using lerna in fixed mode it would be desireable to have lerna generate a consolidated changelog.md file in the root directory that contains changes for all packages. This commit adds said feature, so that, when executing `lerna publish --conventional-commits` it will generate one changelog per package and also one consolidated changelog in the root of the repository. The changelog generation in independent mode stays the same (it generates one changelog per package). Fixes: lerna#1015
ZauberNerd
force-pushed
the
root-changelog-fixed-mode
branch
from
October 16, 2017 22:16
fc92b83 to
e7c880a
Compare
ZauberNerd
force-pushed
the
root-changelog-fixed-mode
branch
from
October 16, 2017 22:28
e7c880a to
bc27b64
Compare
evocateur
approved these changes
Oct 27, 2017
| const args = [ | ||
| CHANGELOG_CLI, | ||
| "-p", "angular", | ||
| "--context", path.resolve(__dirname, "..", "lib", "ConventionalChangelogContext.js"), |
| }); | ||
|
|
||
| if (this.options.conventionalCommits) { | ||
| if (!this.repository.isIndependent()) { |
Member
There was a problem hiding this comment.
I probably would have combined this into one compound conditional (this.options.conventionalCommits && !this.repository.isIndependent()), but I am okay with this.
| // TODO: make interesting git history for meaningful snapshots | ||
| test.skip("--conventional-commits", async () => { | ||
| const cwd = await initFixture("PublishCommand/independent"); | ||
| // TODO: stabilize timestamp and commit sha of changelog output |
Member
There was a problem hiding this comment.
Thanks for the additions here, I hope we can stop skipping these tests soon...
evocateur
added a commit
to mitchhentges/lerna
that referenced
this pull request
Oct 27, 2017
* master: Generate root changelog in fixed mode (lerna#1078) Republish prereleased packages during subsequent non-prerelease publish (lerna#1077) fix: fail when --hoist and --yarn are used together (lerna#1063) Improve "import" edgecases + (i18n fixes + git tweaks) (lerna#1059) Warn about two or more packages having the same npm package.json name (lerna#1081)
This was referenced Feb 2, 2018
|
This thread has been automatically locked because there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
The integration of conventional-changelog into lerna (via the
--conventional-commitsflag) currently generates oneCHANGELOG.mdfile per package.This is fine as long as lerna is configured in "independent mode", but when using lerna in "fixed mode" it might be desirable to additionally generate a consolidated
CHANGELOG.mdin the root directory of the repository.This "root changelog" contains changes for all packages, while the per package changelogs only list changes affecting their package.
Motivation and Context
Based on the discussion in #1015
How Has This Been Tested?
Types of changes
Checklist: