File tree Expand file tree Collapse file tree 1 file changed +60
-0
lines changed Expand file tree Collapse file tree 1 file changed +60
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Site Builder
2+ # This workflow is triggered on pushes to the repository.
3+ on :
4+ push :
5+ pull_request :
6+ release :
7+ types :
8+ - created
9+
10+ jobs :
11+ build :
12+ runs-on : ubuntu-latest
13+ name : " Build the trypyramid.com website"
14+ steps :
15+ - uses : actions/checkout@master
16+ - name : Setup Node.js
17+ uses : actions/setup-node@v1
18+ with :
19+ node-version : ' 13.x'
20+ - run : npm install
21+ - run : npm run build
22+ - name : Upload artifacts
23+ uses : actions/upload-artifact@master
24+ with :
25+ name : built-dist
26+ path : dist
27+
28+ release :
29+ runs-on : ubuntu-latest
30+ if : github.event_name == 'release'
31+ needs : build
32+ steps :
33+ - name : Download the dist artifact
34+ uses : actions/download-artifact@v1
35+ with :
36+ name : built-dist
37+ - name : Zip artifacts
38+ run : zip -r website.zip ./dist/
39+ - name : Upload website.zip to Github release
40+ uses : actions/upload-release-asset@v1
41+ env :
42+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
43+ with :
44+ upload_url : ${{ github.event.release.upload_url }}
45+ asset_path : website.zip
46+ asset_name : website.zip
47+ asset_content_type : application/zip
48+
49+ audit :
50+ runs-on : ubuntu-latest
51+ name : " Audit the NPM packages"
52+ steps :
53+ - uses : actions/checkout@master
54+ - name : Setup Node.js
55+ uses : actions/setup-node@v1
56+ with :
57+ node-version : ' 13.x'
58+ - run : npm install
59+ - run : npm audit
60+ continue-on-error : true
You can’t perform that action at this time.
0 commit comments