Skip to content

Commit 7e6f782

Browse files
Replace unpinned actions with pinned action
1 parent 47d391d commit 7e6f782

File tree

4 files changed

+122
-134
lines changed

4 files changed

+122
-134
lines changed

.github/workflows/badges.yml

+52-54
Original file line numberDiff line numberDiff line change
@@ -5,61 +5,59 @@ on:
55
- develop
66
schedule:
77
- cron: "0 0 * * *"
8-
98
jobs:
109
get-badges:
1110
runs-on: ubuntu-latest
1211
steps:
13-
- uses: actions/checkout@master
14-
- name: Use Node.js
15-
uses: actions/setup-node@v1
16-
with:
17-
node-version: 10.x
18-
- run: npm install
19-
- id: libyear
20-
uses: ./
21-
- run: mkdir badges
22-
- uses: emibcn/badge-action@v1
23-
with:
24-
label: 'libyear drift'
25-
status: ${{ steps.libyear.outputs.drift }} year(s) behind
26-
color: 'blue'
27-
path: 'badges/drift.svg'
28-
- uses: emibcn/badge-action@v1
29-
with:
30-
label: 'libyear pulse'
31-
status: ${{ steps.libyear.outputs.pulse }} year(s) behind
32-
color: 'blue'
33-
path: 'badges/pulse.svg'
34-
- uses: emibcn/badge-action@v1
35-
with:
36-
label: 'libyear'
37-
status: ${{ steps.libyear.outputs.releases }} release(s) behind
38-
color: 'blue'
39-
path: 'badges/releases.svg'
40-
- uses: emibcn/badge-action@v1
41-
with:
42-
label: 'libyear'
43-
status: ${{ steps.libyear.outputs.major }} major release(s) behind
44-
color: 'blue'
45-
path: 'badges/major.svg'
46-
- uses: emibcn/badge-action@v1
47-
with:
48-
label: 'libyear'
49-
status: ${{ steps.libyear.outputs.minor }} minor release(s) behind
50-
color: 'blue'
51-
path: 'badges/minor.svg'
52-
- uses: emibcn/badge-action@v1
53-
with:
54-
label: 'libyear'
55-
status: ${{ steps.libyear.outputs.patch }} patch release(s) behind
56-
color: 'blue'
57-
path: 'badges/patch.svg'
58-
- uses: s0/git-publish-subdir-action@develop
59-
env:
60-
REPO: self
61-
BRANCH: badges
62-
FOLDER: badges
63-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
64-
SQUASH_HISTORY: true
65-
12+
- uses: actions/checkout@61b9e3751b92087fd0b06925ba6dd6314e06f089 # master
13+
- name: Use Node.js
14+
uses: actions/setup-node@f1f314fca9dfce2769ece7d933488f076716723e # v1
15+
with:
16+
node-version: 10.x
17+
- run: npm install
18+
- id: libyear
19+
uses: ./
20+
- run: mkdir badges
21+
- uses: emibcn/badge-action@d5e1c38612d8a624b9b49f9d8c8b5c82cd11ef19 # v1
22+
with:
23+
label: 'libyear drift'
24+
status: ${{ steps.libyear.outputs.drift }} year(s) behind
25+
color: 'blue'
26+
path: 'badges/drift.svg'
27+
- uses: emibcn/badge-action@d5e1c38612d8a624b9b49f9d8c8b5c82cd11ef19 # v1
28+
with:
29+
label: 'libyear pulse'
30+
status: ${{ steps.libyear.outputs.pulse }} year(s) behind
31+
color: 'blue'
32+
path: 'badges/pulse.svg'
33+
- uses: emibcn/badge-action@d5e1c38612d8a624b9b49f9d8c8b5c82cd11ef19 # v1
34+
with:
35+
label: 'libyear'
36+
status: ${{ steps.libyear.outputs.releases }} release(s) behind
37+
color: 'blue'
38+
path: 'badges/releases.svg'
39+
- uses: emibcn/badge-action@d5e1c38612d8a624b9b49f9d8c8b5c82cd11ef19 # v1
40+
with:
41+
label: 'libyear'
42+
status: ${{ steps.libyear.outputs.major }} major release(s) behind
43+
color: 'blue'
44+
path: 'badges/major.svg'
45+
- uses: emibcn/badge-action@d5e1c38612d8a624b9b49f9d8c8b5c82cd11ef19 # v1
46+
with:
47+
label: 'libyear'
48+
status: ${{ steps.libyear.outputs.minor }} minor release(s) behind
49+
color: 'blue'
50+
path: 'badges/minor.svg'
51+
- uses: emibcn/badge-action@d5e1c38612d8a624b9b49f9d8c8b5c82cd11ef19 # v1
52+
with:
53+
label: 'libyear'
54+
status: ${{ steps.libyear.outputs.patch }} patch release(s) behind
55+
color: 'blue'
56+
path: 'badges/patch.svg'
57+
- uses: s0/git-publish-subdir-action@5bc6742efb946f4cba68c7a9067a31ea5631071d # develop
58+
env:
59+
REPO: self
60+
BRANCH: badges
61+
FOLDER: badges
62+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
63+
SQUASH_HISTORY: true

.github/workflows/ci.yml

+30-31
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,41 @@
11
name: Test branch
22
on: push
3-
43
jobs:
54
ci:
65
name: Run Build and check output is checked-in
76
runs-on: ubuntu-latest
87
steps:
9-
- uses: actions/checkout@master
10-
- name: Use Node.js
11-
uses: actions/setup-node@v1
12-
with:
13-
node-version: 10.x
14-
- name: 'Build'
15-
run: |
16-
npm install
17-
npm run build
18-
- name: Check no files have changes
19-
run: git diff --exit-code
8+
- uses: actions/checkout@61b9e3751b92087fd0b06925ba6dd6314e06f089 # master
9+
- name: Use Node.js
10+
uses: actions/setup-node@f1f314fca9dfce2769ece7d933488f076716723e # v1
11+
with:
12+
node-version: 10.x
13+
- name: 'Build'
14+
run: |
15+
npm install
16+
npm run build
17+
- name: Check no files have changes
18+
run: git diff --exit-code
2019
unit-tests:
2120
name: Run Unit Tests
2221
runs-on: ubuntu-latest
2322
steps:
24-
- uses: actions/checkout@master
25-
- name: Use Node.js
26-
uses: actions/setup-node@v1
27-
with:
28-
node-version: 10.x
29-
- name: Install NPM Packages
30-
run: |
31-
npm install
32-
- name: Run Unit Tests
33-
run: |
34-
npm run test -- --coverage
35-
- name: Check Linting
36-
run: |
37-
npm run lint
38-
- name: Submit to CodeCov
39-
uses: codecov/codecov-action@v1
40-
with:
41-
file: ./coverage/lcov.info
42-
fail_ci_if_error: true
23+
- uses: actions/checkout@61b9e3751b92087fd0b06925ba6dd6314e06f089 # master
24+
- name: Use Node.js
25+
uses: actions/setup-node@f1f314fca9dfce2769ece7d933488f076716723e # v1
26+
with:
27+
node-version: 10.x
28+
- name: Install NPM Packages
29+
run: |
30+
npm install
31+
- name: Run Unit Tests
32+
run: |
33+
npm run test -- --coverage
34+
- name: Check Linting
35+
run: |
36+
npm run lint
37+
- name: Submit to CodeCov
38+
uses: codecov/codecov-action@29386c70ef20e286228c72b668a06fd0e8399192 # v1
39+
with:
40+
file: ./coverage/lcov.info
41+
fail_ci_if_error: true

.github/workflows/codeql-analysis.yml

+30-38
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,14 @@
1010
# supported CodeQL languages.
1111
#
1212
name: "CodeQL"
13-
1413
on:
1514
push:
16-
branches: [ develop ]
15+
branches: [develop]
1716
pull_request:
1817
# The branches below must be a subset of the branches above
19-
branches: [ develop ]
18+
branches: [develop]
2019
schedule:
2120
- cron: '19 14 * * 2'
22-
2321
jobs:
2422
analyze:
2523
name: Analyze
@@ -28,44 +26,38 @@ jobs:
2826
actions: read
2927
contents: read
3028
security-events: write
31-
3229
strategy:
3330
fail-fast: false
3431
matrix:
35-
language: [ 'javascript' ]
32+
language: ['javascript']
3633
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ]
3734
# Learn more:
3835
# https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed
39-
4036
steps:
41-
- name: Checkout repository
42-
uses: actions/checkout@v2
43-
44-
# Initializes the CodeQL tools for scanning.
45-
- name: Initialize CodeQL
46-
uses: github/codeql-action/init@v1
47-
with:
48-
languages: ${{ matrix.language }}
49-
# If you wish to specify custom queries, you can do so here or in a config file.
50-
# By default, queries listed here will override any specified in a config file.
51-
# Prefix the list here with "+" to use these queries and those in the config file.
52-
# queries: ./path/to/local/query, your-org/your-repo/queries@main
53-
54-
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
55-
# If this step fails, then you should remove it and run the build manually (see below)
56-
- name: Autobuild
57-
uses: github/codeql-action/autobuild@v1
58-
59-
# ℹ️ Command-line programs to run using the OS shell.
60-
# 📚 https://git.io/JvXDl
61-
62-
# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
63-
# and modify them (or add more) to build your code if your project
64-
# uses a compiled language
65-
66-
#- run: |
67-
# make bootstrap
68-
# make release
69-
70-
- name: Perform CodeQL Analysis
71-
uses: github/codeql-action/analyze@v1
37+
- name: Checkout repository
38+
uses: actions/checkout@ee0669bd1cc54295c223e0bb666b733df41de1c5 # v2
39+
# Initializes the CodeQL tools for scanning.
40+
- name: Initialize CodeQL
41+
uses: github/codeql-action/init@2adeade71c5a811210de40b090a358ed9581536c # v1
42+
with:
43+
languages: ${{ matrix.language }}
44+
# If you wish to specify custom queries, you can do so here or in a config file.
45+
# By default, queries listed here will override any specified in a config file.
46+
# Prefix the list here with "+" to use these queries and those in the config file.
47+
# queries: ./path/to/local/query, your-org/your-repo/queries@main
48+
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
49+
# If this step fails, then you should remove it and run the build manually (see below)
50+
- name: Autobuild
51+
uses: github/codeql-action/autobuild@2adeade71c5a811210de40b090a358ed9581536c # v1
52+
# ℹ️ Command-line programs to run using the OS shell.
53+
# 📚 https://git.io/JvXDl
54+
55+
# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
56+
# and modify them (or add more) to build your code if your project
57+
# uses a compiled language
58+
59+
#- run: |
60+
# make bootstrap
61+
# make release
62+
- name: Perform CodeQL Analysis
63+
uses: github/codeql-action/analyze@2adeade71c5a811210de40b090a358ed9581536c # v1

.github/workflows/libyear.yml

+10-11
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,17 @@
11
name: Libyear
22
on: push
3-
43
jobs:
54
libyear:
65
name: Libyear
76
runs-on: ubuntu-latest
87
steps:
9-
- uses: actions/checkout@master
10-
- name: Use Node.js
11-
uses: actions/setup-node@v1
12-
with:
13-
node-version: 10.x
14-
- name: 'Install NPM Packages'
15-
run: |
16-
npm install
17-
- name: Run libyear action
18-
uses: ./
8+
- uses: actions/checkout@61b9e3751b92087fd0b06925ba6dd6314e06f089 # master
9+
- name: Use Node.js
10+
uses: actions/setup-node@f1f314fca9dfce2769ece7d933488f076716723e # v1
11+
with:
12+
node-version: 10.x
13+
- name: 'Install NPM Packages'
14+
run: |
15+
npm install
16+
- name: Run libyear action
17+
uses: ./

0 commit comments

Comments
 (0)