diff options
-rw-r--r-- | tasks/shfmt/task.yml | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/tasks/shfmt/task.yml b/tasks/shfmt/task.yml new file mode 100644 index 0000000..7d6332c --- /dev/null +++ b/tasks/shfmt/task.yml @@ -0,0 +1,25 @@ +--- +platform: linux +image_resource: + type: registry-image + source: + repository: alpine + tag: latest + +inputs: + - name: repo + +run: + path: ash + args: + - -eufo + - pipefail + - -c + - | + apk add --no-progress --no-interactive shfmt findutils + shfmt --version + find repo \ + -type f \ + -name '*.sh' \ + -print0 |\ + xargs -r0 shfmt -i 8 -d |