File tree Expand file tree Collapse file tree 5 files changed +991
-849
lines changed
Expand file tree Collapse file tree 5 files changed +991
-849
lines changed Original file line number Diff line number Diff line change 1212 check-docs :
1313
1414 runs-on : ubuntu-latest
15+ if : github.repository == 'ExpediaGroup/graphql-kotlin'
1516
1617 steps :
1718 - uses : actions/checkout@v2
2122 with :
2223 node-version : 12
2324
24- - name : Run npm commands
25- if : github.repository == 'ExpediaGroup/graphql-kotlin'
25+ - uses : actions/cache@v1
26+ with :
27+ path : ~/.npm
28+ key : ${{ runner.os }}-node-${{ hashFiles('website/package-lock.json') }}
29+ restore-keys : |
30+ ${{ runner.os }}-node-
31+
32+ - name : Build website
2633 run : |
2734 cd website
2835 npm install
Original file line number Diff line number Diff line change 1212 publish-docs :
1313
1414 runs-on : ubuntu-latest
15+ if : github.repository == 'ExpediaGroup/graphql-kotlin'
1516
1617 steps :
1718 - uses : actions/checkout@v2
@@ -21,18 +22,23 @@ jobs:
2122 with :
2223 node-version : 12
2324
24- - name : Run npm commands
25- if : github.repository == 'ExpediaGroup/graphql-kotlin'
25+ - uses : actions/cache@v1
26+ with :
27+ path : ~/.npm
28+ key : ${{ runner.os }}-node-${{ hashFiles('website/package-lock.json') }}
29+ restore-keys : |
30+ ${{ runner.os }}-node-
31+
32+ - name : Build website
2633 run : |
2734 cd website
2835 npm install
29- git config --global user.name "${GH_USERNAME}"
30- echo "machine github.com login ${GH_USERNAME} password ${{ secrets.EG_CI_USER_TOKEN }}" > ~/.netrc
31- GIT_USER="${GH_USERNAME}" npm run publish-gh-pages
32- env :
33- CI : true
34- CURRENT_BRANCH : master
35-
36- # The following settings will only work with the personal access token we are using
37- # Until GH Actions have a way to publish directly we are using this method
38- GH_USERNAME : eg-oss-ci
36+ npm run build
37+
38+ - name : Deploy GitHub Pages
39+ uses : peaceiris/actions-gh-pages@v3
40+ with :
41+ github_token : ${{ secrets.GITHUB_TOKEN }}
42+ publish_dir : ./build
43+ user_name : eg-oss-ci
44+
You can’t perform that action at this time.
0 commit comments