From b8e15498468ead1fe05b2771af5f086caf27f25f Mon Sep 17 00:00:00 2001 From: Jose Diaz-Gonzalez Date: Fri, 13 Sep 2024 20:32:35 -0400 Subject: [PATCH 1/2] chore: run shfmt --- entrypoint | 48 ++++++++++++++++++++++++------------------------ 1 file changed, 24 insertions(+), 24 deletions(-) diff --git a/entrypoint b/entrypoint index e88c587..fc17020 100755 --- a/entrypoint +++ b/entrypoint @@ -21,31 +21,31 @@ timeout=${TIMEOUT:-30} # Parse arguments while getopts ":t:c:p:" opt; do case $opt in - t) - timeout=$OPTARG - if ! echo "$timeout" | grep -qE '^[0-9]+$'; then - echo "Invalid timeout number: $timeout" >&2 + t) + timeout=$OPTARG + if ! echo "$timeout" | grep -qE '^[0-9]+$'; then + echo "Invalid timeout number: $timeout" >&2 + exit 1 + fi + ;; + c) + TARGETS="$OPTARG" + ;; + p) + PORTS="$OPTARG" + ;; + \?) + set +x + echo "Invalid option: -$OPTARG" >&2 + usage exit 1 - fi - ;; - c) - TARGETS="$OPTARG" - ;; - p) - PORTS="$OPTARG" - ;; - \?) - set +x - echo "Invalid option: -$OPTARG" >&2 - usage - exit 1 - ;; - :) - set +x - echo "Option -$OPTARG requires an argument." >&2 - usage - exit 1 - ;; + ;; + :) + set +x + echo "Option -$OPTARG requires an argument." >&2 + usage + exit 1 + ;; esac done From 8d29b107fe4f486fe79dd9ca21b141ce47938fdd Mon Sep 17 00:00:00 2001 From: Jose Diaz-Gonzalez Date: Fri, 13 Sep 2024 20:33:58 -0400 Subject: [PATCH 2/2] chore: update shfmt settings in lint workflow --- .github/workflows/lint.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml index 7a177dc..98c2d9d 100644 --- a/.github/workflows/lint.yaml +++ b/.github/workflows/lint.yaml @@ -56,7 +56,7 @@ jobs: # v0.3.0 => 7f44869033b40ee4ffe7dc76c87a1bc66e3d025a env: GITHUB_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }} - SHFMT_OPTS: -l -d -i 2 + SHFMT_OPTS: -l -bn -ci -i 2 -d with: sh_checker_shellcheck_disable: true sh_checker_comment: true