Skip to content

Commit

Permalink
Fix shellcheck issues (#75)
Browse files Browse the repository at this point in the history
  • Loading branch information
mszostok committed Jun 8, 2021
1 parent 8800a24 commit e490734
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 10 deletions.
6 changes: 4 additions & 2 deletions hack/compress.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,10 @@ set -o nounset # treat unset variables as an error and exit immediately.
set -o errexit # exit immediately when a command fails.
set -E # needs to be set if we want the ERR trap

readonly CURRENT_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
readonly ROOT_PATH=$( cd "${CURRENT_DIR}/.." && pwd )
CURRENT_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
ROOT_PATH=$( cd "${CURRENT_DIR}/.." && pwd )
readonly CURRENT_DIR
readonly ROOT_PATH

# shellcheck source=./hack/lib/utilities.sh
source "${CURRENT_DIR}/lib/utilities.sh" || { echo 'Cannot load CI utilities.'; exit 1; }
Expand Down
13 changes: 9 additions & 4 deletions hack/run-lint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,15 @@ set -o nounset # treat unset variables as an error and exit immediately.
set -o errexit # exit immediately when a command fails.
set -E # needs to be set if we want the ERR trap

readonly CURRENT_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
readonly ROOT_PATH=$( cd "${CURRENT_DIR}/.." && pwd )
readonly GOLANGCI_LINT_VERSION="v1.31.0"
readonly TMP_DIR=$(mktemp -d)
CURRENT_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
ROOT_PATH=$( cd "${CURRENT_DIR}/.." && pwd )
GOLANGCI_LINT_VERSION="v1.31.0"
TMP_DIR=$(mktemp -d)

readonly CURRENT_DIR
readonly GOLANGCI_LINT_VERSION
readonly ROOT_PATH
readonly TMP_DIR

# shellcheck source=./hack/lib/utilities.sh
source "${CURRENT_DIR}/lib/utilities.sh" || { echo 'Cannot load CI utilities.'; exit 1; }
Expand Down
6 changes: 4 additions & 2 deletions hack/run-test-integration.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,10 @@ set -o nounset # treat unset variables as an error and exit immediately.
set -o errexit # exit immediately when a command fails.
set -E # needs to be set if we want the ERR trap

readonly CURRENT_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
readonly ROOT_PATH=$( cd "${CURRENT_DIR}/.." && pwd )
CURRENT_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
ROOT_PATH=$( cd "${CURRENT_DIR}/.." && pwd )
readonly CURRENT_DIR
readonly ROOT_PATH

# shellcheck source=./hack/lib/utilities.sh
source "${CURRENT_DIR}/lib/utilities.sh" || { echo 'Cannot load CI utilities.'; exit 1; }
Expand Down
7 changes: 5 additions & 2 deletions hack/run-test-unit.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,11 @@ set -o nounset # treat unset variables as an error and exit immediately.
set -o errexit # exit immediately when a command fails.
set -E # needs to be set if we want the ERR trap

readonly CURRENT_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
readonly ROOT_PATH=$( cd "${CURRENT_DIR}/.." && pwd )
CURRENT_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
ROOT_PATH=$( cd "${CURRENT_DIR}/.." && pwd )

readonly CURRENT_DIR
readonly ROOT_PATH

# shellcheck source=./hack/lib/utilities.sh
source "${CURRENT_DIR}/lib/utilities.sh" || { echo 'Cannot load CI utilities.'; exit 1; }
Expand Down

0 comments on commit e490734

Please sign in to comment.