aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Segundo2023-12-31 11:43:48 +0100
committerChristian Segundo2023-12-31 11:43:48 +0100
commit300749d97c8c16dfcaa856579a88dbc35e0f2303 (patch)
treef6e764a1696477dd24c31e7013fa732d90e808cd
parent786cd19a227a20b352b0764c9546c35fa5249ce8 (diff)
downloadconcourse-300749d97c8c16dfcaa856579a88dbc35e0f2303.tar.gz
add shfmt
-rw-r--r--tasks/shfmt/task.yml25
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