Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/lint-github-actions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ permissions: {}

jobs:
lint-github-actions:
name: 🌈 zizmor
name: 🔍 Lint GitHub Actions
runs-on: ubuntu-latest
permissions:
contents: read
Expand Down
39 changes: 39 additions & 0 deletions .github/workflows/lint-secrets.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: 🔍 Lint Secrets

on:
push:
branches:
- main
- beta
pull_request: {}
workflow_dispatch: {}

permissions: {}

jobs:
lint-secrets:
name: 🔍 Lint Secrets
runs-on: ubuntu-latest
permissions:
contents: read

steps:
- name: 📥 Checkout repository
uses: actions/checkout@0c366fd6a839edf440554fa01a7085ccba70ac98 # main
with:
persist-credentials: false

- name: 🔍 Run secretlint
shell: bash
run: |
set -euo pipefail

secretlint_version="$(node -p "require('./package.json').devDependencies.secretlint")"
secretlint_version="${secretlint_version#^}"
secretlint_version="${secretlint_version#~}"
secretlint_version="${secretlint_version#v}"

docker run --rm --network none \
-v "${PWD}:${PWD}" -w "${PWD}" \
"secretlint/secretlint:v${secretlint_version}" \
secretlint --format github "**/*"
7 changes: 7 additions & 0 deletions .secretlintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"rules": [
{
"id": "@secretlint/secretlint-rule-preset-recommend"
}
]
}
1 change: 1 addition & 0 deletions lint-staged.config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
export default {
"*": ["secretlint --no-glob"],
"*.{js,jsx,ts,tsx,html,css,json,json5,md}": ["prettier --write"],
"!(.github/workflows)/*.{yml,yaml}": ["prettier --write"],
".github/workflows/*.{yml,yaml}": [
Expand Down
Loading