Fix syntax-check: remove commit count gate, use pacman for Arch
Syntax Check / syntax-check (push) Failing after 3s
Syntax Check / syntax-check (push) Failing after 3s
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
name: Syntax Check (Every 2 Commits)
|
||||
name: Syntax Check
|
||||
|
||||
on:
|
||||
push:
|
||||
@@ -8,16 +8,13 @@ on:
|
||||
jobs:
|
||||
syntax-check:
|
||||
runs-on: archlinux
|
||||
if: ${{ github.event.commits && github.event.commits.length >= 2 }}
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Install linting tools
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y shellcheck
|
||||
pip install --break-system-packages yamllint
|
||||
pacman -Syu --noconfirm --needed shellcheck python-yamllint
|
||||
|
||||
- name: Lint shell scripts with ShellCheck
|
||||
run: |
|
||||
@@ -111,7 +108,7 @@ jobs:
|
||||
# Skip empty lines and comments
|
||||
[[ -z "$line" || "$line" =~ ^# ]] && continue
|
||||
|
||||
# Check for invalid characters (package names should be alphanumeric, hyphens, dots, underscores, @)
|
||||
# Check for invalid characters
|
||||
if [[ ! "$line" =~ ^[a-zA-Z0-9._@+\-]+$ ]]; then
|
||||
echo "❌ Line $LINENUM: invalid package name format: '$line'"
|
||||
FAILED=1
|
||||
|
||||
Reference in New Issue
Block a user