Skip to content

Commit 5a44ddf

Browse files
committed
chore(ci):Fix github action syntax
Also ensure build command is part of the docs generation job ref: STARGAZER-2760
1 parent 2e3d963 commit 5a44ddf

File tree

1 file changed

+30
-9
lines changed

1 file changed

+30
-9
lines changed

.github/workflows/build.yml

Lines changed: 30 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -77,15 +77,36 @@ jobs:
7777
runs-on: ubuntu-latest
7878

7979
steps:
80-
- name: Generate storybook documentation
81-
run: yarn build:storybook
82-
83-
- name: Generate storybook documentation
84-
run: yarn build:storybook
85-
uses: JamesIves/[email protected]
86-
with:
87-
branch: gh-pages # The branch the action should deploy to.
88-
folder: .docs # The folder the action should deploy.
80+
- name: Checkout
81+
uses: actions/checkout@v2
82+
83+
- name: Setup Node.js
84+
uses: actions/setup-node@v2
85+
with:
86+
node-version: ${{ env.NODE_VERSION }}
87+
88+
- name: Cache node_modules
89+
uses: actions/cache@v2
90+
id: cache-nodemodules
91+
with:
92+
path: node_modules
93+
key: ${{ runner.os }}-${{ env.NODE_VERSION }}-nodemodules-${{ hashFiles('**/yarn.lock') }}
94+
95+
- name: Install dependencies
96+
if: steps.cache-nodemodules.outputs.cache-hit != 'true'
97+
run: yarn install --frozen-lockfile --non-interactive
98+
99+
- name: Build latest app
100+
run: yarn build
101+
102+
- name: Generate storybook documentation
103+
run: yarn build:storybook
104+
105+
- name: Deploy storybook documentation to gh-pages
106+
uses: JamesIves/[email protected]
107+
with:
108+
branch: gh-pages # The branch the action should deploy to.
109+
folder: .docs # The folder the action should deploy.
89110

90111
release:
91112
needs: [tests, lint, docs]

0 commit comments

Comments
 (0)