forked from open-telemetry/opentelemetry-python
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(lerna): add lerna-changelog (open-telemetry#432)
* chore(lerna): add lerna-changelog closes open-telemetry#372 add docs related to lerna-changelog Signed-off-by: Olivier Albertini <olivier.albertini@montreal.ca> * fix: add draffensperger recommendations Signed-off-by: Olivier Albertini <olivier.albertini@montreal.ca>
- Loading branch information
1 parent
4c0626c
commit ddf43ff
Showing
5 changed files
with
67 additions
and
6 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -68,3 +68,6 @@ packages/**/package-lock.json | |
docs | ||
|
||
.nyc_output | ||
|
||
#lerna | ||
.changelog |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# Releasing OpenTelemetry Packages (for Maintainers Only) | ||
|
||
This document explains how to publish all OT modules at version x.y.z. Ensure that you’re following semver when choosing a version number. | ||
|
||
## Use the Changelog to create a GitHub Release | ||
|
||
### Generate the changelog with lerna | ||
|
||
Since we use `lerna`, we can use [lerna-changelog](https://github.com/lerna/lerna-changelog#lerna-changelog) | ||
|
||
#### How to use | ||
Pass your [github token](https://help.github.com/en/articles/creating-a-personal-access-token-for-the-command-line) to generate the changelog automatically. | ||
For security reasons, when you create a Github token, select the permissions: under **repo**, select **Access public repositories**, **commit status**. | ||
|
||
In your terminal, execute the following command: | ||
```bash | ||
GITHUB_AUTH=<your token> lerna-changelog | ||
``` | ||
It will print something like: | ||
|
||
```md | ||
## Unreleased (2018-05-24) | ||
|
||
#### :bug: Bug Fix | ||
* [#198](https://github.com/my-org/my-repo/pull/198) Avoid an infinite loop ([@helpful-hacker](https://github.com/helpful-hacker)) | ||
|
||
#### :house: Internal | ||
* [#183](https://github.com/my-org/my-repo/pull/183) Standardize error messages ([@careful-coder](https://github.com/careful-coder)) | ||
|
||
#### Commiters: 2 | ||
- Helpful Hacker ([@helpful-hacker](https://github.com/helpful-hacker)) | ||
- [@careful-coder](https://github.com/careful-coder) | ||
``` | ||
By default lerna-changelog will show all pull requests that have been merged since the latest tagged commit in the repository. That is however only true for pull requests **with certain labels applied** (see [lerna.json](lerna.json) for authorized labels). | ||
|
||
You can also use the `--from` and `--to` options to view a different range of pull requests: | ||
``` | ||
GITHUB_AUTH=xxxxx lerna-changelog --from=v1.0.0 --to=v2.0.0 | ||
``` | ||
|
||
#### Update Changelog file | ||
|
||
From what `lerna-changelog` has generated, starts new Unreleased label. Follow the example set by recent Released label. |
This file contains 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
This file contains 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