Skip to content

Commit

Permalink
ci(pre-commit): Run shfmt, shellcheck on fixtures
Browse files Browse the repository at this point in the history
  • Loading branch information
yedayak committed Sep 15, 2024
1 parent e8dc253 commit 497345f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ repos:
hooks:
- id: shfmt
types: [text]
files: ^(bash_completion(\.d/[^/]+\.bash)?|completions/.+|test/(config/bashrc|fallback/update-fallback-links|runLint|update-test-cmd-list)|.+\.sh(\.in)?)$
files: ^(bash_completion(\.d/[^/]+\.bash)?|completions/.+|test/(config/bashrc|fixtures/.+/bin/.+|fallback/update-fallback-links|runLint|update-test-cmd-list)|.+\.sh(\.in)?)$
exclude: ^completions/(\.gitignore|Makefile.*)$

- repo: https://github.com/shellcheck-py/shellcheck-py
Expand All @@ -22,7 +22,7 @@ repos:
- id: shellcheck
args: [-f, gcc]
types: [text]
files: ^(bash_completion(\.d/[^/]+\.bash)?|completions/.+|test/(config/bashrc|fallback/update-fallback-links|runLint|update-test-cmd-list)|.+\.sh(\.in)?)$
files: ^(bash_completion(\.d/[^/]+\.bash)?|completions/.+|test/(config/bashrc|fixtures/.+/bin/.+|fallback/update-fallback-links|runLint|update-test-cmd-list)|.+\.sh(\.in)?)$
exclude: ^completions/(\.gitignore|Makefile.*)$
require_serial: false # We disable SC1090 anyway, so parallel is ok

Expand Down
4 changes: 2 additions & 2 deletions test/fixtures/mount/bin/showmount
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#!/bin/bash

if [ "$1" = -e ] && [ "$2" = mocksrv ]; then
if [[ $1 == -e && $2 == "mocksrv" ]]; then
echo "Header line"
echo "/test/path"
echo "/test/path2"
Expand Down

0 comments on commit 497345f

Please sign in to comment.