Skip to content

Commit a695908

Browse files
committed
Add test to actions workflows
1 parent 8c9e377 commit a695908

5 files changed

Lines changed: 77 additions & 6 deletions

File tree

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# SPDX-FileCopyrightText: Copyright (C) 2025 Fabrício Barros Cabral
2+
# SPDX-License-Identifier: MIT
3+
---
4+
# yamllint disable rule:line-length
5+
name: action-lint-test
6+
'on':
7+
push:
8+
branches:
9+
- main
10+
- master
11+
pull_request:
12+
branches:
13+
- main
14+
- master
15+
permissions:
16+
contents: read
17+
jobs:
18+
action-lint-test:
19+
uses: fabriciofx/github-workflows/.github/workflows/action-lint-template.yml@main

.github/workflows/action-security-template.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,16 @@
55
name: action-security-template
66
'on':
77
workflow_call:
8+
inputs:
9+
working-directory:
10+
description: "Set the working directory"
11+
required: false
12+
default: ".github/workflows/"
13+
type: string
14+
secrets:
15+
GITHUB_TOKEN:
16+
description: "GitHub Token"
17+
required: true
818
defaults:
919
run:
1020
shell: bash -xeuo pipefail {0}
@@ -24,4 +34,4 @@ jobs:
2434
uses: zizmorcore/zizmor-action@873539476a7f9b0da7504d0d9e9a6a5275094d98
2535
with:
2636
token: ${{ secrets.GITHUB_TOKEN }}
27-
inputs: .github/workflows/
37+
inputs: ${{ inputs.working-directory }}
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# SPDX-FileCopyrightText: Copyright (C) 2025 Fabrício Barros Cabral
2+
# SPDX-License-Identifier: MIT
3+
---
4+
# yamllint disable rule:line-length
5+
name: action-security-test
6+
'on':
7+
push:
8+
branches:
9+
- main
10+
- master
11+
pull_request:
12+
branches:
13+
- main
14+
- master
15+
permissions:
16+
actions: read
17+
contents: read
18+
security-events: write
19+
jobs:
20+
action-security-test:
21+
uses: fabriciofx/github-workflows/.github/workflows/action-security-template.yml@main
22+
secrets:
23+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/action-update-template.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ name: action-update-template
66
'on':
77
workflow_call:
88
secrets:
9-
GH_TOKEN:
10-
description: 'GitHub token'
9+
GITHUB_TOKEN:
10+
description: "GitHub token"
1111
required: true
1212
defaults:
1313
run:
@@ -25,8 +25,8 @@ jobs:
2525
- name: Setup node.js
2626
uses: actions/setup-node@v5
2727
with:
28-
node-version: '22'
29-
- name: Run renovate
28+
node-version: 22
29+
- name: Run Renovate
3030
uses: renovatebot/github-action@ed4d0bb582ff6e994d0252a7715bd5b80f25d106
3131
with:
32-
token: ${{ secrets.GH_TOKEN }}
32+
token: ${{ secrets.GITHUB_TOKEN }}
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# SPDX-FileCopyrightText: Copyright (C) 2025 Fabrício Barros Cabral
2+
# SPDX-License-Identifier: MIT
3+
---
4+
# yamllint disable rule:line-length
5+
name: action-update-test
6+
'on':
7+
schedule:
8+
- cron: '0 2 * * *'
9+
workflow_dispatch:
10+
defaults:
11+
run:
12+
shell: bash -xeuo pipefail {0}
13+
permissions:
14+
contents: read
15+
jobs:
16+
action-update-test:
17+
uses: fabriciofx/github-workflows/.github/workflows/action-update-template.yml@main
18+
secrets:
19+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)