forked from NHSDigital/nhsuk-react-components-extensions
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
725b591
commit 670e765
Showing
3 changed files
with
56 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
name: CD Build and Publish to NPM | ||
|
||
on: | ||
release: | ||
types: [published] | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
packages: write | ||
contents: read | ||
steps: | ||
- uses: actions/checkout@v1 | ||
|
||
- name: Yarn Install | ||
run: yarn | ||
|
||
- name: Lint | ||
run: yarn lint | ||
|
||
- name: Jest Tests | ||
run: yarn test:ci | ||
|
||
- name: Typescript build | ||
run: yarn build | ||
|
||
- name: Set Version to Release Tag Name | ||
run: | | ||
yarn version --new-version ${{ github.event.release.tag_name }} --no-git-tag-version | ||
- uses: actions/setup-node@v3 | ||
with: | ||
registry-url: 'https://npm.pkg.github.com' | ||
- run: npm publish | ||
env: | ||
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,23 @@ | ||
name: Build & Deploy Storybook | ||
# name: Build & Deploy Storybook | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
# on: | ||
# push: | ||
# branches: | ||
# - master | ||
|
||
jobs: | ||
build-and-deploy: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@master | ||
with: | ||
persist-credentials: false | ||
# jobs: | ||
# build-and-deploy: | ||
# runs-on: ubuntu-latest | ||
# steps: | ||
# - name: Checkout | ||
# uses: actions/checkout@master | ||
# with: | ||
# persist-credentials: false | ||
|
||
- name: Yarn Install | ||
run: yarn install | ||
# - name: Yarn Install | ||
# run: yarn install | ||
|
||
- name: Deploy Storybook | ||
run: yarn storybook-to-ghpages --ci | ||
env: | ||
GH_TOKEN: ${{ secrets.ACCESS_TOKEN }} | ||
# - name: Deploy Storybook | ||
# run: yarn storybook-to-ghpages --ci | ||
# env: | ||
# GH_TOKEN: ${{ secrets.ACCESS_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters