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

Commit 5a5b6d5

Browse files
committed
feat(ci): enable semanitic-release
Lint commits by husky. Add package-lock.json
1 parent 36404cf commit 5a5b6d5

File tree

5 files changed

+13045
-1
lines changed

5 files changed

+13045
-1
lines changed

.travis.yml

+12
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,19 @@ before_install:
1212

1313
before_script:
1414
- npm install -g grunt-cli
15+
- echo "TRAVIS_COMMIT $TRAVIS_COMMIT"
16+
- echo "TRAVIS_PULL_REQUEST_SHA $TRAVIS_PULL_REQUEST_SHA"
17+
- COMMIT_TO_VALIDATE=${TRAVIS_PULL_REQUEST_SHA:-$TRAVIS_COMMIT}
18+
- echo "COMMIT_TO_VALIDATE $COMMIT_TO_VALIDATE"
19+
- 'if [ "$VALIDATE_COMMIT_MSG" == "true" ]; then ./scripts/validate-commit-msg.sh $COMMIT_TO_VALIDATE; fi'
1520

1621
script:
1722
- npm run test:lib
1823
- grunt
24+
25+
after_success:
26+
# run automated release process with semantic-release
27+
- echo "TRAVIS_BRANCH=$TRAVIS_BRANCH, TRAVIS_EVENT_TYPE=$TRAVIS_EVENT_TYPE, TRAVIS_NODE_VERSION=$TRAVIS_NODE_VERSION"
28+
- if [[ "$TRAVIS_BRANCH" == "master" && "$TRAVIS_EVENT_TYPE" == "push" && "$TRAVIS_NODE_VERSION" == "12" ]]; then
29+
npm run semantic-release;
30+
fi;

commitlint.config.js

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
module.exports = {extends: ['@commitlint/config-conventional']}

0 commit comments

Comments
 (0)