Skip to content

Commit

Permalink
Merge pull request #10 from mrseanryan/chore/unpin-dev-deps
Browse files Browse the repository at this point in the history
Chore/unpin dev deps
  • Loading branch information
mrseanryan authored Jan 4, 2020
2 parents 2a6afdc + 124226b commit 6997bb7
Show file tree
Hide file tree
Showing 3 changed files with 179 additions and 1,031 deletions.
53 changes: 40 additions & 13 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,47 @@
# validate here: https://config.travis-ci.com/explore
language: node_js
os: linux

cache:
directories:
- ~/.npm
yarn: true

notifications:
email: false
email: false

node_js:
- "12"
- "10"
# - "8" - disabled: too old for commitizen
# - '6' - disabled: [email protected] requires node >=8.3
script:
- npm run test:prod
after_success:
- npm run travis-deploy-once "npm run report-coverage"
- if [ "$TRAVIS_BRANCH" = "master" -a "$TRAVIS_PULL_REQUEST" = "false" ]; then npm run travis-deploy-once "npm run deploy-docs"; fi
- if [ "$TRAVIS_BRANCH" = "master" -a "$TRAVIS_PULL_REQUEST" = "false" ]; then npm run travis-deploy-once "npm run semantic-release"; fi
- "12"
- "10"
# - "8" - disabled: too old for commitizen
# - '6' - disabled: [email protected] requires node >=8.3

install:
- yarn

stages:
# stages run in sequence
- 'Test' # default stage, that runs 'yarn test'
- name: 'Code-coverage'
- name: 'Deploy'
if: branch = master AND type = push

jobs:
include:
# 'Test' runs 'yarn test' default

- stage: 'Code-coverage'
name: 'Report code coverage to coveralls'
node_js: "12"
before_script: yarn test # each stage gets a fresh environment: so need to run tests again here, to have coverage file
script: yarn report-coverage

- stage: 'Deploy'
name: 'Deploy to docs and to npm'
node_js: "12"
# jobs in same stage will run in parallel:
before_script: yarn build # each stage runs in a fresh environment
script: yarn deploy-docs
script: yarn semantic-release

branches:
except:
- /^v\d+\.\d+\.\d+$/
16 changes: 6 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,11 @@
"@commitlint/config-conventional": "^8.2.0",
"@types/jest": "^24.0.25",
"@types/lodash": "^4.14.149",
"@types/node": "13.1.2",
"@types/node": "^13.1.2",
"colors": "^1.4.0",
"commitizen": "^4.0.3",
"coveralls": "^3.0.9",
"cross-env": "6.0.3",
"cross-env": "^6.0.3",
"cz-conventional-changelog": "^3.0.2",
"husky": "^3.1.0",
"jest": "^24.9.0",
Expand All @@ -86,7 +86,6 @@
"replace-in-file": "^5.0.2",
"rimraf": "^3.0.0",
"semantic-release": "^15.14.0",
"travis-deploy-once": "^5.0.11",
"ts-jest": "^24.2.0",
"ts-node": "^8.5.4",
"tslint": "^5.20.1",
Expand All @@ -109,22 +108,19 @@
"prebuild": "rimraf dist",
"build": "tsc --module commonjs && typedoc --out docs --target es6 --theme minimal --mode file src",
"build:minimal": "tsc --module commonjs",
"build-and-test": "yarn build:minimal && yarn test",
"start": "yarn clean && yarn build && yarn test && yarn lint",
"test": "yarn tsl:test && yarn test:unit",
"test": "yarn build:minimal && yarn lint && yarn tsl:test && yarn test:unit",
"test:unit": "jest --coverage",
"test:watch": "jest --coverage --watch",
"test:prod": "npm run build && npm run lint && npm run test -- --no-cache",
"test:prod": "yarn build && yarn lint && yarn test -- --no-cache",
"tsl:build-and-test": "yarn build && yarn tsl:test",
"tsl:test": "tslint --test test/rules/**/tslint.json",
"tsl:test-with-diagrams": "tslint --test test/rules/**/tslint.json",
"tsl:test-one": "tslint --test test/rules/tsf-folders-disabled-test/**/tslint.json",
"deploy-docs": "ts-node tools/gh-pages-publish",
"report-coverage": "cat ./coverage/lcov.info | coveralls",
"commit": "git-cz",
"semantic-release": "semantic-release",
"semantic-release-prepare": "ts-node tools/semantic-release-prepare",
"travis-deploy-once": "travis-deploy-once"
"semantic-release-prepare": "ts-node tools/semantic-release-prepare"
},
"repository": {
"type": "git",
Expand All @@ -149,7 +145,7 @@
"husky": {
"hooks": {
"pre-commit": "lint-staged",
"pre-push": "npm run test:prod"
"pre-push": "yarn test:prod"
}
}
}
Loading

0 comments on commit 6997bb7

Please sign in to comment.