Skip to content

Commit

Permalink
ci: fix filters on tags for publishing to npm and deployment of docs (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
brandonroberts authored Aug 27, 2019
1 parent 2d37b48 commit 7445dd4
Showing 1 changed file with 29 additions and 20 deletions.
49 changes: 29 additions & 20 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,11 @@ jobs:
- ~/.cache/yarn
- ~/.cache/Cypress
- node_modules
# required since `publish-*` jobs have tag filters AND requires `test`
# https://circleci.com/docs/2.0/workflows/#executing-workflows-for-a-git-tag
filters:
tags:
only: /.*/

schematics-core-check:
<<: *run_in_browser
Expand Down Expand Up @@ -211,7 +216,9 @@ jobs:
- run:
name: Authenticate with registry
command: echo "//registry.npmjs.org/:_authToken=$npm_TOKEN" > ~/repo/.npmrc
- run: yarn run publish:stable
- run:
name: Publish stable to npm
command: ./node_modules/.bin/ts-node ./build/publish-stable.ts

publish-next:
<<: *run_in_node
Expand All @@ -224,7 +231,9 @@ jobs:
- run:
name: Authenticate with registry
command: echo "//registry.npmjs.org/:_authToken=$npm_TOKEN" > ~/repo/.npmrc
- run: yarn run publish:next
- run:
name: Publish next to npm
command: ./node_modules/.bin/ts-node ./build/publish-next.ts

cleanup-previews:
<<: *run_in_node
Expand Down Expand Up @@ -282,27 +291,27 @@ workflows:
filters:
branches:
only: master
# - publish-stable:
# requires:
# - test
# filters:
# branches:
# ignore: /.*/
# tags:
# only: /\d+\.\d+\.\d+(?!-\w+\.\d)/
# - deploy-docs-stable:
# requires:
# - test
# filters:
# branches:
# ignore: /.*/
# tags:
# only: /\d+\.\d+\.\d+(?!-\w+\.\d)/
- publish-next:
- publish-stable:
requires:
- test
filters:
tags:
only: /8\.\d+\.\d+(?!-\w+\.\d)/
branches:
ignore: /.*/
- deploy-docs-stable:
requires:
- test
filters:
tags:
only: /\d+\.\d+\.\d+(-\w+\.\d)/
only: /8\.\d+\.\d+(?!-\w+\.\d)/
branches:
ignore: /.*/
- publish-next:
requires:
- test
filters:
tags:
only: /8\.\d+\.\d+(-\w+\.\d)/
branches:
ignore: /.*/

0 comments on commit 7445dd4

Please sign in to comment.