Skip to content
This repository was archived by the owner on Aug 7, 2023. It is now read-only.

Commit db39e4a

Browse files
authored
Merge pull request #178 from keplersj/continous-deployment
Initial Adoption of Continous Deployment using semantic-release
2 parents 60c6ba6 + 62f7ff4 commit db39e4a

File tree

2 files changed

+53
-9
lines changed

2 files changed

+53
-9
lines changed

.travis.yml

Lines changed: 37 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,42 @@
11
### Project specific config ###
2-
language: generic
2+
language: node_js
3+
node_js: lts/*
4+
install: skip
5+
os: linux
36

4-
matrix:
7+
jobs:
58
include:
6-
- os: linux
9+
# Test Atom versions
10+
- stage: test
711
env: ATOM_CHANNEL=stable
8-
9-
- os: linux
12+
- stage: test
1013
env: ATOM_CHANNEL=beta
1114

15+
# Check the commit messages and run the extra lint script
16+
- stage: test
17+
install:
18+
- npm install
19+
before_script: skip
20+
script:
21+
- commitlint-travis
22+
- npm run lint
23+
24+
- stage: release
25+
# Since the deploy needs APM, currently the simplest method is to run
26+
# build-package.sh, which requires the specs to pass.
27+
before_deploy:
28+
- export PATH=${PATH}:${HOME}/atom/usr/bin/
29+
deploy:
30+
provider: script
31+
skip_cleanup: true
32+
script:
33+
- npx semantic-release
34+
1235
### Generic setup follows ###
1336
script:
1437
- curl -s -O https://raw.githubusercontent.com/atom/ci/master/build-package.sh
1538
- chmod u+x build-package.sh
16-
- ./build-package.sh
39+
- "./build-package.sh"
1740

1841
notifications:
1942
email:
@@ -23,6 +46,7 @@ notifications:
2346
branches:
2447
only:
2548
- master
49+
- "/^greenkeeper/.*$/"
2650

2751
git:
2852
depth: 10
@@ -35,6 +59,11 @@ addons:
3559
apt:
3660
packages:
3761
- build-essential
38-
- fakeroot
3962
- git
40-
- libsecret-1-dev
63+
- libgnome-keyring-dev
64+
- fakeroot
65+
66+
stages:
67+
- test
68+
- name: release
69+
if: (NOT type = pull_request) AND branch = master

package.json

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
}
2929
},
3030
"scripts": {
31+
"commitmsg": "commitlint -e $GIT_PARAMS",
3132
"test": "apm test",
3233
"lint": "eslint ."
3334
},
@@ -49,10 +50,16 @@
4950
"tiny-promisify": "^1.0.0"
5051
},
5152
"devDependencies": {
53+
"@commitlint/cli": "^7.0.0",
54+
"@commitlint/config-conventional": "^7.0.1",
55+
"@commitlint/travis-cli": "^7.0.0",
56+
"@semantic-release/apm-config": "^5.0.2",
5257
"eslint": "^4.6.0",
5358
"eslint-config-airbnb-base": "^12.0.0",
5459
"eslint-plugin-import": "^2.7.0",
55-
"jasmine-fix": "^1.3.1"
60+
"husky": "^0.14.3",
61+
"jasmine-fix": "^1.3.1",
62+
"semantic-release": "^15.9.0"
5663
},
5764
"eslintConfig": {
5865
"rules": {
@@ -88,5 +95,13 @@
8895
"1.0.0": "provideLinter"
8996
}
9097
}
98+
},
99+
"release": {
100+
"extends": "@semantic-release/apm-config"
101+
},
102+
"commitlint": {
103+
"extends": [
104+
"@commitlint/config-conventional"
105+
]
91106
}
92107
}

0 commit comments

Comments
 (0)