File tree 8 files changed +39
-94
lines changed
8 files changed +39
-94
lines changed Original file line number Diff line number Diff line change
1
+ name : Basic validation
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - main
7
+ paths-ignore :
8
+ - ' **.md'
9
+ pull_request :
10
+ paths-ignore :
11
+ - ' **.md'
12
+
13
+ jobs :
14
+ call-basic-validation :
15
+ name : Basic validation
16
+ uses : actions/reusable-workflows/.github/workflows/basic-validation.yml@main
Original file line number Diff line number Diff line change 1
- # `dist/index.js` is a special file in Actions.
2
- # When you reference an action with `uses:` in a workflow,
3
- # `index.js` is the code that will run.
4
- # For our project, we generate this file through a build process from other source files.
5
- # We need to make sure the checked-in `index.js` actually matches what we expect it to be.
6
1
name : Check dist/
7
2
8
3
on :
17
12
workflow_dispatch :
18
13
19
14
jobs :
20
- check-dist :
21
- runs-on : ubuntu-latest
22
-
23
- steps :
24
- - uses : actions/checkout@v3
25
-
26
- - name : Set Node.js 16.x
27
- uses : actions/setup-node@v3
28
- with :
29
- node-version : 16.x
30
- cache : npm
31
-
32
- - name : Install dependencies
33
- run : npm ci
34
-
35
- - name : Rebuild the dist/ directory
36
- run : npm run build
37
-
38
- - name : Compare the expected and actual dist/ directories
39
- run : |
40
- if [ "$(git diff --ignore-space-at-eol dist/ | wc -l)" -gt "0" ]; then
41
- echo "Detected uncommitted changes after build. See status below:"
42
- git diff
43
- exit 1
44
- fi
45
- id : diff
46
-
47
- # If index.js was different than expected, upload the expected version as an artifact
48
- - uses : actions/upload-artifact@v3
49
- if : ${{ failure() && steps.diff.conclusion == 'failure' }}
50
- with :
51
- name : dist
52
- path : dist/
15
+ call-check-dist :
16
+ name : Check dist/
17
+ uses : actions/reusable-workflows/.github/workflows/check-dist.yml@main
Original file line number Diff line number Diff line change
1
+ name : CodeQL analysis
2
+
3
+ on :
4
+ push :
5
+ branches : [ main ]
6
+ pull_request :
7
+ branches : [ main ]
8
+ schedule :
9
+ - cron : ' 0 3 * * 0'
10
+
11
+ jobs :
12
+ call-codeQL-analysis :
13
+ name : CodeQL analysis
14
+ uses : actions/reusable-workflows/.github/workflows/codeql-analysis.yml@main
Original file line number Diff line number Diff line change 9
9
- main
10
10
11
11
jobs :
12
- test :
13
- runs-on : ubuntu-latest
14
- name : Check licenses
15
- steps :
16
- - uses : actions/checkout@v3
17
- - name : Set Node.js 16.x
18
- uses : actions/setup-node@v3
19
- with :
20
- node-version : 16.x
21
- - run : npm ci
22
- - name : Install licensed
23
- run : |
24
- cd $RUNNER_TEMP
25
- curl -Lfs -o licensed.tar.gz https://github.com/github/licensed/releases/download/3.4.4/licensed-3.4.4-linux-x64.tar.gz
26
- sudo tar -xzf licensed.tar.gz
27
- sudo mv licensed /usr/local/bin/licensed
28
- - run : licensed status
12
+ call-licensed :
13
+ name : Licensed
14
+ uses : actions/reusable-workflows/.github/workflows/licensed.yml@main
Original file line number Diff line number Diff line change 1
1
name : Release new action version
2
+
2
3
on :
3
4
release :
4
5
types : [released]
Original file line number Diff line number Diff line change 1
1
name : Validate 'setup-go'
2
+
2
3
on :
3
4
push :
4
5
branches :
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 8
8
"build" : " tsc && ncc build -o dist/setup src/setup-go.ts && ncc build -o dist/cache-save src/cache-save.ts" ,
9
9
"format" : " prettier --write **/*.ts" ,
10
10
"format-check" : " prettier --check **/*.ts" ,
11
+ "lint" : " echo \" Fake command that does nothing. It is used in reusable workflows\" " ,
11
12
"test" : " jest --coverage" ,
12
13
"pre-checkin" : " npm run format && npm run build && npm test"
13
14
},
You can’t perform that action at this time.
0 commit comments