Skip to content

Commit 69347ff

Browse files
authored
Merge pull request #3857 from gofiber/workflows-update
🧹 chore: Improvements to GitHub Workflows
2 parents 9892282 + 2e8502d commit 69347ff

16 files changed

Lines changed: 84 additions & 107 deletions

.github/labeler.yml

Lines changed: 0 additions & 23 deletions
This file was deleted.

.github/release-drafter.yml

Lines changed: 27 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,16 +35,13 @@ exclude-contributors:
3535
version-resolver:
3636
major:
3737
labels:
38-
- 'major'
3938
- '❗ BreakingChange'
4039
minor:
4140
labels:
42-
- 'minor'
4341
- '✏️ Feature'
4442
- '📝 Proposal'
4543
patch:
4644
labels:
47-
- 'patch'
4845
- '📒 Documentation'
4946
- '☢️ Bug'
5047
- '🤖 Dependencies'
@@ -56,4 +53,30 @@ template: |
5653
5754
**Full Changelog**: https://github.com/$OWNER/$REPOSITORY/compare/$PREVIOUS_TAG...v$RESOLVED_VERSION
5855
59-
Thank you $CONTRIBUTORS for making this update possible.
56+
Thank you $CONTRIBUTORS for making this release possible.
57+
58+
autolabeler:
59+
- label: '📒 Documentation'
60+
matcher:
61+
title: '/(docs|doc:|\[doc\]|README|typos|comment|documentation)/i'
62+
- label: '☢️ Bug'
63+
matcher:
64+
title: '/(fix|race|bug|missing|correct)/i'
65+
- label: '🧹 Updates'
66+
matcher:
67+
title: '/(improve|improvements|update|refactor|deprecated|remove|unused|test)/i'
68+
- label: '🤖 Dependencies'
69+
matcher:
70+
title: '/(bump|dependencies)/i'
71+
- label: '✏️ Feature'
72+
matcher:
73+
title: '/(feature|feat|create|implement|add)/i'
74+
- label: '📝 Proposal'
75+
matcher:
76+
title: '/(proposal|idea|request|suggest)/i'
77+
- label: 'v3'
78+
branch:
79+
- '/main/'
80+
- label: 'v2'
81+
branch:
82+
- '/v2/'

.github/workflows/auto-labeler.yml

Lines changed: 0 additions & 24 deletions
This file was deleted.

.github/workflows/benchmark.yml

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,11 @@ on:
22
push:
33
branches:
44
- main
5-
paths:
6-
- "**.go"
7-
- "go.mod"
8-
- "go.sum"
5+
paths-ignore:
6+
- "**/*.md"
97
pull_request:
10-
paths:
11-
- "**.go"
12-
- "go.mod"
13-
- "go.sum"
8+
paths-ignore:
9+
- "**/*.md"
1410

1511
permissions:
1612
# deployments permission to deploy GitHub pages website
@@ -26,12 +22,12 @@ jobs:
2622
runs-on: ubuntu-latest
2723
steps:
2824
- name: Fetch Repository
29-
uses: actions/checkout@v5
25+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
3026
with:
3127
fetch-depth: 0 # to be able to retrieve the last commit in main
3228

3329
- name: Install Go
34-
uses: actions/setup-go@v6
30+
uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
3531
with:
3632
# NOTE: Keep this in sync with the version from go.mod
3733
go-version: "1.25.x"
@@ -71,7 +67,7 @@ jobs:
7167

7268
# NOTE: Benchmarks could change with different CPU types
7369
- name: Get GitHub Runner System Information
74-
uses: kenchan0130/actions-system-info@v1.4.0
70+
uses: kenchan0130/actions-system-info@59699597e84e80085a750998045983daa49274c4 # v1.4.0
7571
id: system-info
7672

7773
- name: Get Main branch SHA
@@ -82,14 +78,14 @@ jobs:
8278
8379
- name: Get Benchmark Results from main branch
8480
id: cache
85-
uses: actions/cache/restore@v4
81+
uses: actions/cache/restore@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
8682
with:
8783
path: ./cache
8884
key: ${{ steps.get-main-branch-sha.outputs.sha }}-${{ runner.os }}-${{ steps.system-info.outputs.cpu-model }}-benchmark
8985

9086
# This will only run if we have Benchmark Results from main branch
9187
- name: Compare PR Benchmark Results with main branch
92-
uses: benchmark-action/github-action-benchmark@v1.20.7
88+
uses: benchmark-action/github-action-benchmark@4bdcce38c94cec68da58d012ac24b7b1155efe8b # v1.20.7
9389
if: steps.cache.outputs.cache-hit == 'true'
9490
with:
9591
tool: 'go'
@@ -105,7 +101,7 @@ jobs:
105101
alert-threshold: "150%"
106102

107103
- name: Store Benchmark Results for main branch
108-
uses: benchmark-action/github-action-benchmark@v1.20.7
104+
uses: benchmark-action/github-action-benchmark@4bdcce38c94cec68da58d012ac24b7b1155efe8b # v1.20.7
109105
if: ${{ github.ref_name == 'main' }}
110106
with:
111107
tool: 'go'
@@ -119,7 +115,7 @@ jobs:
119115
alert-threshold: "150%"
120116

121117
- name: Publish Benchmark Results to GitHub Pages
122-
uses: benchmark-action/github-action-benchmark@v1.20.7
118+
uses: benchmark-action/github-action-benchmark@4bdcce38c94cec68da58d012ac24b7b1155efe8b # v1.20.7
123119
if: ${{ github.ref_name == 'main' }}
124120
with:
125121
tool: 'go'
@@ -137,7 +133,7 @@ jobs:
137133
auto-push: false
138134

139135
- name: Update Benchmark Results cache
140-
uses: actions/cache/save@v4
136+
uses: actions/cache/save@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
141137
if: ${{ github.ref_name == 'main' }}
142138
with:
143139
path: ./cache

.github/workflows/codeql-analysis.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919

2020
steps:
2121
- name: Checkout repository
22-
uses: actions/checkout@v5
22+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
2323
with:
2424
# We must fetch at least the immediate parents so that if this is
2525
# a pull request then we can checkout the head.
@@ -32,15 +32,15 @@ jobs:
3232

3333
# Initializes the CodeQL tools for scanning.
3434
- name: Initialize CodeQL
35-
uses: github/codeql-action/init@v4
35+
uses: github/codeql-action/init@0499de31b99561a6d14a36a5f662c2a54f91beee # v4.31.2
3636
# Override language selection by uncommenting this and choosing your languages
3737
with:
3838
languages: go
3939

4040
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
4141
# If this step fails, then you should remove it and run the build manually (see below)
4242
- name: Autobuild
43-
uses: github/codeql-action/autobuild@v4
43+
uses: github/codeql-action/autobuild@0499de31b99561a6d14a36a5f662c2a54f91beee # v4.31.2
4444

4545
# ℹ️ Command-line programs to run using the OS shell.
4646
# 📚 https://git.io/JvXDl
@@ -54,4 +54,4 @@ jobs:
5454
# make release
5555

5656
- name: Perform CodeQL Analysis
57-
uses: github/codeql-action/analyze@v4
57+
uses: github/codeql-action/analyze@0499de31b99561a6d14a36a5f662c2a54f91beee # v4.31.2

.github/workflows/linter.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,16 +23,16 @@ jobs:
2323
name: lint
2424
runs-on: ubuntu-latest
2525
steps:
26-
- uses: actions/checkout@v5
26+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
2727

28-
- uses: actions/setup-go@v6
28+
- uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
2929
with:
3030
# NOTE: Keep this in sync with the version from go.mod
3131
go-version: "1.25.x"
3232
cache: false
3333

3434
- name: golangci-lint
35-
uses: golangci/golangci-lint-action@v8
35+
uses: golangci/golangci-lint-action@0a35821d5c230e903fcfe077583637dea1b27b47 # v9.0.0
3636
with:
3737
# NOTE: Keep this in sync with the version from .golangci.yml
3838
version: v2.5.0

.github/workflows/manual-dependabot.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
runs-on: ubuntu-latest
2626
steps:
2727
- name: Checkout repo
28-
uses: actions/checkout@v5
28+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
2929

3030
- name: Checkout dependabot
3131
run: |

.github/workflows/markdown.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,21 @@ on:
44
push:
55
branches:
66
- main
7+
paths:
8+
- "**/*.md"
79
pull_request:
10+
paths:
11+
- "**/*.md"
812

913
jobs:
1014
markdownlint:
1115
runs-on: ubuntu-latest
1216
steps:
1317
- name: Fetch Repository
14-
uses: actions/checkout@v5
18+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
1519

1620
- name: Run markdownlint-cli2
17-
uses: DavidAnson/markdownlint-cli2-action@v20
21+
uses: DavidAnson/markdownlint-cli2-action@992badcdf24e3b8eb7e87ff9287fe931bcb00c6e # v20.0.0
1822
with:
1923
globs: |
2024
**/*.md

.github/workflows/modernize.yml

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,13 @@ on:
44
push:
55
branches:
66
- main
7-
paths:
8-
- "**.go"
9-
- "!**/*_msgp*.go"
10-
- "go.mod"
11-
- "go.sum"
7+
paths-ignore:
8+
- "**/*.md"
9+
- "**/*_msgp*.go"
1210
pull_request:
13-
paths:
14-
- "**.go"
15-
- "!**/*_msgp*.go"
16-
- "go.mod"
17-
- "go.sum"
11+
paths-ignore:
12+
- "**/*.md"
13+
- "**/*_msgp*.go"
1814

1915
permissions:
2016
contents: read
@@ -25,9 +21,9 @@ jobs:
2521
modernize:
2622
runs-on: ubuntu-latest
2723
steps:
28-
- uses: actions/checkout@v5
24+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
2925

30-
- uses: actions/setup-go@v6
26+
- uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
3127
with:
3228
# NOTE: Keep this in sync with the version from go.mod
3329
go-version: "1.25.x"

.github/workflows/release-drafter.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
# echo "GHE_HOST=${GITHUB_SERVER_URL##https:\/\/}" >> $GITHUB_ENV
1616

1717
# Drafts your next Release notes as Pull Requests are merged into "master"
18-
- uses: release-drafter/release-drafter@v6
18+
- uses: release-drafter/release-drafter@b1476f6e6eb133afa41ed8589daba6dc69b4d3f5 # v6.1.0
1919
# (Optional) specify config name to use, relative to .github/. Default: release-drafter.yml
2020
# with:
2121
# config-name: my-config.yml

0 commit comments

Comments
 (0)