mirror of
https://github.com/ChrisTitusTech/linutil.git
synced 2024-12-25 12:59:45 +00:00
Fixed (#623)
This commit is contained in:
parent
8c5b5702bd
commit
83a61a093f
15
.github/workflows/bashisms.yml
vendored
15
.github/workflows/bashisms.yml
vendored
|
@ -1,10 +1,6 @@
|
|||
name: Check for bashisms
|
||||
|
||||
on:
|
||||
# push:
|
||||
# paths:
|
||||
# - core/tabs/**
|
||||
# branches: [ "main" ]
|
||||
pull_request:
|
||||
paths:
|
||||
- core/tabs/**
|
||||
|
@ -20,18 +16,19 @@ jobs:
|
|||
- run: git fetch origin ${{ github.base_ref }}
|
||||
|
||||
- name: Get a list of changed script files
|
||||
run : |
|
||||
id: get_sh_files
|
||||
run: |
|
||||
sh_files=$(git diff --name-only origin/${{ github.base_ref }} HEAD core/tabs | grep '\.sh$' || true)
|
||||
echo "sh_files=$sh_files" >> $GITHUB_ENV
|
||||
echo "::set-output name=sh_files::$sh_files"
|
||||
|
||||
- name: Install devscripts
|
||||
if: env.sh_files != ''
|
||||
if: steps.get_sh_files.outputs.sh_files != ''
|
||||
run: sudo apt-get update && sudo apt-get install devscripts
|
||||
|
||||
- name: Check for bashisms
|
||||
if: env.sh_files != ''
|
||||
if: steps.get_sh_files.outputs.sh_files != ''
|
||||
run: |
|
||||
for file in ${{ env.sh_files }}; do
|
||||
for file in ${{ steps.get_sh_files.outputs.sh_files }}; do
|
||||
if [[ -f "$file" ]]; then
|
||||
checkbashisms "$file"
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue
Block a user