Compare commits

...

4 Commits

Author SHA1 Message Date
312c00f77f feat(pr-lint): switch to cupcake megalinter (#105) 2025-04-08 03:26:26 +03:00
f845a14b12 fix(pr-lint): add missing shell definitions (#103) 2025-04-07 11:04:42 +03:00
renovate[bot]
9870d3ee6c feat(github-action): update ivuorinen/actions (25.3.25 → 25.4.5) (#102)
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-07 05:20:10 +00:00
renovate[bot]
8619a7832f feat(github-action): update actions/dependency-review-action (v4.5.0 → v4.6.0) (#100)
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-07 01:38:22 +03:00
4 changed files with 17 additions and 12 deletions

View File

@@ -13,4 +13,4 @@ jobs:
- name: 'Checkout Repository' - name: 'Checkout Repository'
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: 'Dependency Review' - name: 'Dependency Review'
uses: actions/dependency-review-action@3b139cfc5fae8b618d3eae3675e383bb1769c019 # v4.5.0 uses: actions/dependency-review-action@ce3cf9537a52e8119d91fd484ab5b8a807627bf8 # v4.6.0

View File

@@ -29,12 +29,12 @@ repos:
args: [-c, .markdownlint.json, --fix] args: [-c, .markdownlint.json, --fix]
- repo: https://github.com/adrienverge/yamllint - repo: https://github.com/adrienverge/yamllint
rev: v1.35.1 rev: v1.37.0
hooks: hooks:
- id: yamllint - id: yamllint
- repo: https://github.com/scop/pre-commit-shfmt - repo: https://github.com/scop/pre-commit-shfmt
rev: v3.10.0-2 rev: v3.11.0-1
hooks: hooks:
- id: shfmt - id: shfmt
@@ -51,12 +51,12 @@ repos:
args: ['-shellcheck='] args: ['-shellcheck=']
- repo: https://github.com/renovatebot/pre-commit-hooks - repo: https://github.com/renovatebot/pre-commit-hooks
rev: 39.156.0 rev: 39.227.2
hooks: hooks:
- id: renovate-config-validator - id: renovate-config-validator
- repo: https://github.com/bridgecrewio/checkov.git - repo: https://github.com/bridgecrewio/checkov.git
rev: '3.2.360' rev: '3.2.400'
hooks: hooks:
- id: checkov - id: checkov
args: args:

View File

@@ -29,11 +29,11 @@ runs:
# ╰──────────────────────────────────────────────────────────╯ # ╰──────────────────────────────────────────────────────────╯
- name: Setup Git Config - name: Setup Git Config
id: git-config id: git-config
uses: ivuorinen/actions/set-git-config@d648dba57309a3437c6f7996fdacb478c5a99916 # 25.3.25 uses: ivuorinen/actions/set-git-config@730304e2936e7afeab4ac5652d448d0ded2fbe4b # 25.4.5
# ╭──────────────────────────────────────────────────────────╮ # ╭──────────────────────────────────────────────────────────╮
# │ Install packages for linting │ # │ Install packages for linting │
# ╰──────────────────────────────────────────────────────────╯ # ╰──────────────────────────────────────────────────────────╯
# Node.js tests if package.json exists # Node.js tests if package.json exists
- name: Detect package.json - name: Detect package.json
@@ -52,6 +52,7 @@ runs:
- name: Install Node.js dependencies - name: Install Node.js dependencies
if: steps.detect-node.outputs.found == 'true' if: steps.detect-node.outputs.found == 'true'
shell: bash
run: npm ci run: npm ci
# PHP tests if composer.json exists # PHP tests if composer.json exists
@@ -74,10 +75,12 @@ runs:
- name: Setup problem matchers for PHP - name: Setup problem matchers for PHP
if: steps.detect-php.outputs.found == 'true' if: steps.detect-php.outputs.found == 'true'
shell: bash
run: echo "::add-matcher::${{ runner.tool_cache }}/php.json" run: echo "::add-matcher::${{ runner.tool_cache }}/php.json"
- name: Install PHP dependencies - name: Install PHP dependencies
if: steps.detect-php.outputs.found == 'true' if: steps.detect-php.outputs.found == 'true'
shell: bash
run: composer install --no-progress --prefer-dist --no-interaction run: composer install --no-progress --prefer-dist --no-interaction
# Python tests if requirements.txt exists # Python tests if requirements.txt exists
@@ -97,6 +100,7 @@ runs:
- name: Install Python dependencies - name: Install Python dependencies
if: steps.detect-python.outputs.found == 'true' if: steps.detect-python.outputs.found == 'true'
shell: bash
run: pip install -r requirements.txt run: pip install -r requirements.txt
# Go tests if go.mod exists # Go tests if go.mod exists
@@ -121,7 +125,7 @@ runs:
- name: MegaLinter - name: MegaLinter
# You can override MegaLinter flavor used to have faster performances # You can override MegaLinter flavor used to have faster performances
# More info at https://megalinter.io/latest/flavors/ # More info at https://megalinter.io/latest/flavors/
uses: oxsecurity/megalinter@146333030da68e2e58c6ff826633824fabe01eaf # v8.5.0 uses: oxsecurity/megalinter/flavors/cupcake@146333030da68e2e58c6ff826633824fabe01eaf # v8.5.0
id: ml id: ml
# All available variables are described in documentation # All available variables are described in documentation

5
run.sh
View File

@@ -78,7 +78,8 @@ find . -mindepth 1 -maxdepth 1 -type d | while read -r dir; do
echo "- ⏩ Skipping $dir - action.yml missing" echo "- ⏩ Skipping $dir - action.yml missing"
fi fi
) || { ) || {
echo "- ⚠️ Warning: Error processing directory $dir" | tee -a "$log_file" echo "- ⚠️ Warning: Error processing directory $dir" |
tee -a "$log_file"
} }
echo "" echo ""
done done
@@ -106,7 +107,7 @@ fi
echo "" echo ""
echo "🔎 Running MegaLinter..." echo "🔎 Running MegaLinter..."
if ! npx --yes mega-linter-runner; then if ! npx --yes mega-linter-runner --flavor cupcake --fix --remove-container --container-name cupcake; then
echo "- ⚠️ Warning: MegaLinter found issues" | tee -a "$log_file" echo "- ⚠️ Warning: MegaLinter found issues" | tee -a "$log_file"
fi fi
echo "" echo ""