Skip to content

Commit d7dcbfa

Browse files
author
Markus Günther
committed
Build: Introduce sematic-release with commitizen
We are now using semantic-release with the eslint commit message rules re #26
1 parent a929fd9 commit d7dcbfa

File tree

4 files changed

+2918
-139
lines changed

4 files changed

+2918
-139
lines changed

.releaserc

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"branch": "master",
3+
"analyzeCommits": {
4+
"preset": "eslint"
5+
}
6+
}

.travis.yml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,21 @@ language: node_js
22
sudo: false
33
cache:
44
directories:
5+
- ~/.npm
56
- node_modules
7+
notifications:
8+
email: false
69
node_js:
7-
- "node"
10+
- '10'
11+
- '9'
12+
- '8'
13+
- '6'
814
before_install:
915
- curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version 1.9.4
1016
- export PATH="$HOME/.yarn/bin:$PATH"
1117
- yarn global add babel-cli
18+
after_success:
19+
- npm run travis-deploy-once "npm run semantic-release"
20+
branches:
21+
except:
22+
- /^v\d+\.\d+\.\d+$/

package.json

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"author": "Javi Velasco <javier.velasco86@gmail.com> (http://javivelasco.com/)",
88
"repository": {
99
"type": "git",
10-
"url": "git+https://github.com/FriendsOfReactJS/react-css-themr.git"
10+
"url": "https://github.com/FriendsOfReactJS/react-css-themr.git"
1111
},
1212
"bugs": {
1313
"url": "https://github.com/FriendsOfReactJS/react-css-themr/issues"
@@ -33,6 +33,9 @@
3333
"babel-preset-es2015": "^6.24.1",
3434
"babel-preset-react": "^6.24.1",
3535
"babel-preset-stage-0": "^6.24.1",
36+
"commitizen": "^2.10.1",
37+
"conventional-changelog-eslint": "^3.0.0",
38+
"cz-adapter-eslint": "^0.1.2",
3639
"eslint": "^5.3.0",
3740
"eslint-config-prettier": "^3.0.0",
3841
"eslint-plugin-prettier": "^2.6.2",
@@ -45,7 +48,9 @@
4548
"react": "^16.4.2",
4649
"react-dom": "^16.4.2",
4750
"rimraf": "^2.6.2",
48-
"sinon": "^6.1.4"
51+
"semantic-release": "^15.9.8",
52+
"sinon": "^6.1.4",
53+
"travis-deploy-once": "^5.0.2"
4954
},
5055
"files": [
5156
"index.d.ts",
@@ -58,7 +63,10 @@
5863
"lint-check": "eslint --print-config .eslintrc.js | eslint-config-prettier-check",
5964
"prepublish": "rimraf lib && npm run build",
6065
"test": "jest",
61-
"test:watch": "npm test -- --watch"
66+
"test:watch": "npm test -- --watch",
67+
"travis-deploy-once": "travis-deploy-once",
68+
"semantic-release": "semantic-release",
69+
"commit": "git-cz"
6270
},
6371
"license": "MIT",
6472
"peerDependencies": {
@@ -72,5 +80,10 @@
7280
"jest": {
7381
"verbose": true,
7482
"testURL": "http://localhost/"
83+
},
84+
"config": {
85+
"commitizen": {
86+
"path": "./node_modules/cz-adapter-eslint"
87+
}
7588
}
7689
}

0 commit comments

Comments
 (0)