Skip to content

Commit 2f18ca8

Browse files
author
Robert Jackson
authored
Merge pull request #694 from rwjblue/add-release-setup
Add automated release setup.
2 parents 9a8856b + c6e7210 commit 2f18ca8

6 files changed

Lines changed: 1747 additions & 29 deletions

File tree

.travis.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,3 +32,6 @@ cache:
3232
before_install:
3333
- npm config set spin false
3434
- npm install -g npm@4
35+
36+
install:
37+
- yarn --ignore-engines

CHANGELOG.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
# ember-cli-fastboot changelog
2-
31
## 2.0.4
42

53
* Fix issue in IE11 when using `Array.from`

RELEASE.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# Release
2+
3+
Releases are mostly automated using
4+
[release-it](https://github.com/release-it/release-it/) and
5+
[lerna-changelog](https://github.com/lerna/lerna-changelog/).
6+
7+
8+
## Preparation
9+
10+
Since the majority of the actual release process is automated, the primary
11+
remaining task prior to releasing is confirming that all pull requests that
12+
have been merged since the last release have been labeled with the appropriate
13+
`lerna-changelog` labels and the titles have been updated to ensure they
14+
represent something that would make sense to our users. Some great information
15+
on why this is important can be found at
16+
[keepachangelog.com](https://keepachangelog.com/en/1.0.0/), but the overall
17+
guiding principles here is that changelogs are for humans, not machines.
18+
19+
When reviewing merged PR's the labels to be used are:
20+
21+
* breaking - Used when the PR is considered a breaking change.
22+
* enhancement - Used when the PR adds a new feature or enhancement.
23+
* bug - Used when the PR fixes a bug included in a previous release.
24+
* documentation - Used when the PR adds or updates documentation.
25+
* internal - Used for internal changes that still require a mention in the
26+
changelog/release notes.
27+
28+
29+
## Release
30+
31+
Once the prep work is completed, the actual release is straight forward:
32+
33+
```
34+
yarn install
35+
yarn release
36+
```
37+
38+
The `release` script leverages
39+
[release-it](https://github.com/release-it/release-it/) to do the mechanical
40+
release process. It will prompt you through the process of choosing the version
41+
number, tagging, pushing the tag and commits, etc.

appveyor.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ install:
2121
- appveyor-retry npm i -g bower # for ember-cli-addon-tests
2222
- npm --version
2323
- appveyor-retry choco install phantomjs
24-
- appveyor-retry yarn
25-
- appveyor-retry yarn add mocha-appveyor-reporter # must be installed locally.
24+
- appveyor-retry yarn --ignore-engines
25+
- appveyor-retry yarn add mocha-appveyor-reporter --ignore-engines # must be installed locally.
2626

2727

2828
# Post-install test scripts.

package.json

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
"scripts": {
1616
"build": "ember build",
1717
"lint:js": "eslint ./*.js addon addon-test-support app config lib server test-support tests",
18+
"release": "release-it",
1819
"start": "ember serve",
1920
"test": "mocha && ember test",
2021
"test:precook": "node node_modules/ember-cli-addon-tests/scripts/precook-node-modules.js"
@@ -70,16 +71,34 @@
7071
"loader.js": "^4.7.0",
7172
"mocha": "^5.2.0",
7273
"qunit-dom": "^0.8.0",
74+
"release-it": "^12.0.1",
75+
"release-it-lerna-changelog": "^1.0.2",
7376
"request": "^2.88.0",
7477
"rsvp": "^4.8.3"
7578
},
7679
"engines": {
7780
"node": "6.* || 8.* || >= 10.*"
7881
},
82+
"publishConfig": {
83+
"registry": "https://registry.npmjs.org/"
84+
},
7985
"ember-addon": {
8086
"configPath": "tests/dummy/config",
8187
"before": [
8288
"broccoli-serve-files"
8389
]
90+
},
91+
"release-it": {
92+
"plugins": {
93+
"release-it-lerna-changelog": {
94+
"infile": "CHANGELOG.md"
95+
}
96+
},
97+
"git": {
98+
"tagName": "v${version}"
99+
},
100+
"github": {
101+
"release": true
102+
}
84103
}
85104
}

0 commit comments

Comments
 (0)