Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Storybook Continuous Delivery #105

Merged
merged 2 commits into from
May 6, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,5 @@ matrix:
- env: SUITE=COMPONENT_LIBRARY
script:
- yarn run travis
after_success:
- make deploy
27 changes: 27 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -42,3 +42,30 @@ travis:
@if [ "$$SUITE" = "COMPONENT_LIBRARY" ]; then \
cd packages/component-library && yarn test && cd -; \
fi

deploy:
@if [ -z "$$TRAVIS_PULL_REQUEST" ] || [ "$$TRAVIS_PULL_REQUEST" = "false" ]; then \
echo "Not a PR..."; \
if [ "$$TRAVIS_BRANCH" = "master" ]; then \
echo "On the master branch..."; \
if [ "$$SUITE" = "2017" ]; then \
make deploy-2017; \
fi; \
if [ "$$SUITE" = "2018" ]; then \
make deploy-2018; \
fi; \
if [ "$$SUITE" = "COMPONENT_LIBRARY" ]; then \
make deploy-component-library; \
fi \
fi \
fi

deploy-2017:
echo "2017 build and deploy stub"

deploy-2018:
echo "2018 build and deploy stub"

deploy-component-library:
@echo "Deploying the component library";
yarn run deploy-storybook -- --ci;