Skip to content

Commit

Permalink
chore: update gh-pages deploy (#674)
Browse files Browse the repository at this point in the history
  • Loading branch information
jzempel committed Mar 12, 2020
1 parent d0360b1 commit cc6f6c9
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 5 deletions.
12 changes: 7 additions & 5 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@ references:
attach_workspace:
at: *workspace_root

persist_to_workspace: &persist_to_workspace
persist_to_workspace:
root: *workspace_root
paths: .

jobs:
build:
<<: *executor
Expand All @@ -26,9 +31,7 @@ jobs:
- run: yarn --frozen-lockfile --ignore-scripts
- run: yarn lerna bootstrap
- run: yarn lerna run build --concurrency=2 # prevent out-of-memory
- persist_to_workspace:
root: *workspace_root
paths: .
- *persist_to_workspace

test:
<<: *executor
Expand All @@ -39,6 +42,7 @@ jobs:
- run: yarn tsc
- run: yarn test:all --coverage --runInBand
- run: '[ $COVERALLS_REPO_TOKEN ] && yarn coveralls < demo/coverage/lcov.info || true'
- *persist_to_workspace

deploy:
<<: *executor
Expand All @@ -47,8 +51,6 @@ jobs:
steps:
- *attach_workspace
- run: yarn lerna run build:demo --concurrency=2 # prevent out-of-memory
- run: git config user.email 'sayhi@circleci.com'
- run: git config user.name 'CircleCI'
- run: utils/scripts/gh-pages.js

publish:
Expand Down
5 changes: 5 additions & 0 deletions utils/scripts/gh-pages.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,10 @@ const ghPages = require('gh-pages');

ghPages.publish('demo', {
repo: `https://${process.env.GITHUB_TOKEN}@github.com/zendeskgarden/react-components.git`,
user: {
name: 'Zendesk Garden',
email: 'garden@zendesk.com'
},
message: 'Updates [skip ci]',
silent: true
});

0 comments on commit cc6f6c9

Please sign in to comment.