Fix shellcheck issues (#1341)

* Fix issue with latest shellcheck version

The latest shellcheck versions use a new error number for non-POSIX
string replacement. Change to ignore this new error number.

* Ignore shellcheck issue about not following sourced files

Newer shellcheck versions also warn when shellcheck does not follow
sourcing of files with known path:
  Not following: ./meta was not specified as input (see shellcheck -x).

We check those files separately so ignore this error for the two scripts
affected.
This commit is contained in:
Stefan Agner 2021-04-29 01:15:47 +02:00 committed by GitHub
parent 99a4d4ea75
commit f86fcbd609
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 4 deletions

View File

@ -9,13 +9,13 @@ case "$1" in
exit 0 exit 0
fi fi
# Be compatible with hassos OS ID # Be compatible with hassos OS ID
# shellcheck disable=SC2039 # shellcheck disable=SC3060
rauc_os_compatible=${RAUC_MF_COMPATIBLE/haos-/hassos-} rauc_os_compatible=${RAUC_MF_COMPATIBLE/haos-/hassos-}
if [ "$rauc_os_compatible" = "$RAUC_SYSTEM_COMPATIBLE" ]; then if [ "$rauc_os_compatible" = "$RAUC_SYSTEM_COMPATIBLE" ]; then
exit 0 exit 0
fi fi
# generic-x86-64: Be compatible with intel-nuc # generic-x86-64: Be compatible with intel-nuc
# shellcheck disable=SC2039 # shellcheck disable=SC3060
rauc_board_compatible=${rauc_os_compatible/generic-x86-64/intel-nuc} rauc_board_compatible=${rauc_os_compatible/generic-x86-64/intel-nuc}
if [ "${rauc_board_compatible}" = "$RAUC_SYSTEM_COMPATIBLE" ]; then if [ "${rauc_board_compatible}" = "$RAUC_SYSTEM_COMPATIBLE" ]; then
exit 0 exit 0

View File

@ -1,5 +1,5 @@
#!/bin/bash #!/bin/bash
# shellcheck disable=SC1090 # shellcheck disable=SC1090,SC1091
set -e set -e
SCRIPT_DIR=${BR2_EXTERNAL_HASSOS_PATH}/scripts SCRIPT_DIR=${BR2_EXTERNAL_HASSOS_PATH}/scripts

View File

@ -1,5 +1,5 @@
#!/bin/bash #!/bin/bash
# shellcheck disable=SC1090 # shellcheck disable=SC1090,SC1091
set -e set -e
SCRIPT_DIR=${BR2_EXTERNAL_HASSOS_PATH}/scripts SCRIPT_DIR=${BR2_EXTERNAL_HASSOS_PATH}/scripts