Skip to content

Commit 76ab79e

Browse files
authored
Merge branch 'qualcomm-linux:main' into main
2 parents 77e7e03 + 8e078f4 commit 76ab79e

File tree

76 files changed

+4742
-1023
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

76 files changed

+4742
-1023
lines changed
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Enforce Script Executable Permissions
2+
3+
on:
4+
pull_request_target:
5+
branches: [ "main" ]
6+
paths:
7+
- '**/run.sh'
8+
- '**/*.sh'
9+
push:
10+
branches: [ "main" ]
11+
workflow_dispatch:
12+
13+
jobs:
14+
permissions:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- name: Checkout code
18+
uses: actions/checkout@v4
19+
20+
- name: Detect missing executable permissions on shell scripts
21+
run: |
22+
# Find all .sh and run.sh scripts without +x
23+
BAD=$(find . -type f \( -name "*.sh" -o -name "run.sh" \) ! -perm -u=x)
24+
if [ -n "$BAD" ]; then
25+
echo "::error file=run.sh,line=1::❌ Some shell scripts are missing executable permissions. This can break CI and LAVA. Please fix before merging."
26+
echo "::error file=run.sh,line=2::To fix, run: find . -name '*.sh' -o -name 'run.sh' | xargs chmod +x && git add . && git commit -m 'Fix: restore executable bits on scripts' && git push"
27+
echo ""
28+
echo "The following scripts need 'chmod +x':"
29+
echo "$BAD"
30+
# Output a PR annotation for each file
31+
echo "$BAD" | while read -r file; do
32+
echo "::error file=$file,line=1::$file is not executable. Please run: chmod +x $file && git add $file"
33+
done
34+
exit 1
35+
else
36+
echo "✅ All shell scripts have correct executable permissions."
37+
fi
38+
39+
- name: Detect accidental executables on non-shell files (optional, warning only)
40+
run: |
41+
# (Advanced/optional) Warn if any non-.sh file has +x (customize as needed)
42+
OTHER_EXEC=$(find . -type f ! -name '*.sh' ! -name 'run.sh' -perm -u=x)
43+
if [ -n "$OTHER_EXEC" ]; then
44+
echo "::warning file=run.sh,line=1::Warning: Non-shell files with executable permissions detected. Review if needed."
45+
echo "$OTHER_EXEC"
46+
fi

.github/workflows/copyright-license-checker-action.yml

Lines changed: 0 additions & 31 deletions
This file was deleted.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: preflight-checkers
2+
on:
3+
pull_request_target:
4+
branches: [ "main" ]
5+
push:
6+
branches: [ "main" ]
7+
workflow_dispatch:
8+
9+
permissions:
10+
contents: read
11+
security-events: write
12+
13+
jobs:
14+
checker:
15+
uses: qualcomm-linux/qli-actions/.github/workflows/multi-checker.yml@main
16+
with:
17+
repolinter: true # default: true
18+
semgrep: true # default: true
19+
copyright-license-detector: true # default: true
20+
pr-check-emails: true # default: true
21+
22+
secrets:
23+
SEMGREP_APP_TOKEN: ${{ secrets.SEMGREP_APP_TOKEN }}

.github/workflows/qualcomm-organization-repolinter.yml

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

.github/workflows/shellcheck.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: Shell Lint
2+
3+
on:
4+
pull_request_target:
5+
branches: [ "main" ]
6+
push:
7+
branches: [ "main" ]
8+
workflow_dispatch:
9+
10+
jobs:
11+
shellcheck:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v3
15+
- name: Install ShellCheck 0.9.0-1
16+
run: sudo apt-get install -y shellcheck=0.9.0-1
17+
- name: Run ShellCheck with exclusions
18+
run: |
19+
find . -name '*.sh' -print0 | xargs -0 shellcheck -S warning -e SC1091,SC2230,SC3043

0 commit comments

Comments
 (0)