diff options
author | William Harrington <kb0iic@berzerkula.org> | 2021-04-08 18:50:46 -0500 |
---|---|---|
committer | William Harrington <kb0iic@berzerkula.org> | 2021-04-08 18:53:44 -0500 |
commit | ab42e4c660a6f25bae5a5388bc140953a87a3248 (patch) | |
tree | c7b8f80f69bed1cd903236bc14bbdb4015ee35f4 | |
parent | 58ed189f35f6c972aa30711d1889707a5808aa48 (diff) |
Add shellcheck directives.
-rw-r--r-- | chapter5/glibc.sh | 2 | ||||
-rw-r--r-- | chapter6/backup.sh | 2 | ||||
-rw-r--r-- | chapter7/backup.sh | 2 | ||||
-rw-r--r-- | insidechroot.sh | 2 | ||||
-rw-r--r-- | packageinstall.sh | 1 |
5 files changed, 8 insertions, 1 deletions
diff --git a/chapter5/glibc.sh b/chapter5/glibc.sh index 8997613..edab0d3 100644 --- a/chapter5/glibc.sh +++ b/chapter5/glibc.sh @@ -30,4 +30,4 @@ readelf -l a.out | grep '/ld-linux' && rm -v dummy.c a.out && -"${LFS}"/tools/libexec/gcc/"${LFS_TGT}"/10.2.0/install-tools/mkheaders +"${LFS}"/tools/libexec/gcc/"${LFS_TGT}"/10.3.0/install-tools/mkheaders diff --git a/chapter6/backup.sh b/chapter6/backup.sh index a27440b..43e8b18 100644 --- a/chapter6/backup.sh +++ b/chapter6/backup.sh @@ -9,6 +9,7 @@ else printf "%b" "${GRN}Backing up ${YLW}${LFS}${GRN} to ${YLW}${file}${RST}... " pushd "${LFS}" > /dev/null || exit 1 + # shellcheck disable=SC2024 sudo XZ_OPTS="-T${NUMPROCS} -e" tar cJvpf "${HOME}"/"${file}" "${directories[@]}" >/"${LFS}"/sources/log/chapter6/backup.log 2>&1 & pid=$! spinner "$pid" "${SPINNER}" retval=$? @@ -16,6 +17,7 @@ else printf "%b" "${IRED}FAILED!${RST}\n" exit "${retval}" else + # shellcheck disable=SC2024 sudo chown -v "${USER}":"$(id -g)" "${HOME}"/"${file}" >>"${LFS}"/sources/log/chapter6/backup.log printf "%b" "${IGRN}OK${RST}\n" fi diff --git a/chapter7/backup.sh b/chapter7/backup.sh index 7cfb29f..38d626f 100644 --- a/chapter7/backup.sh +++ b/chapter7/backup.sh @@ -9,6 +9,7 @@ else printf "%b" "${GRN}Backing up ${YLW}${LFS}${GRN} to ${YLW}${file}${RST}... " pushd "${LFS}" > /dev/null || exit 1 + # shellcheck disable=SC2024 sudo XZ_OPTS="-T${NUMPROCS} -e" tar cJvpf "${HOME}"/"${file}" "${directories[@]}" >"${LFS}"/sources/log/chapter7/backup.log 2>&1 & pid=$! spinner "$pid" "${SPINNER}" retval=$? @@ -16,6 +17,7 @@ else printf "%b" "${IRED}FAILED!${RST}\n" exit "${retval}" else + # shellcheck disable=SC2024 sudo chown -v "${USER}":"$(id -g)" "${HOME}"/"${file}" >"${LFS}"/sources/log/chapter7/backup.log 2>&1 printf "%b" "${IGRN}OK${RST}\n" fi diff --git a/insidechroot.sh b/insidechroot.sh index 28cf64f..72357ac 100644 --- a/insidechroot.sh +++ b/insidechroot.sh @@ -2,7 +2,9 @@ CHAPTER="$1" +# shellcheck source=colors.sh source /sources/colors.sh +# shellcheck source=functions.sh source /sources/functions.sh printf "%b" "${CYN}SUCCESSFULLY ENTERED ${RED}CHROOT${RST}!\n" diff --git a/packageinstall.sh b/packageinstall.sh index df09148..706880c 100644 --- a/packageinstall.sh +++ b/packageinstall.sh @@ -37,6 +37,7 @@ else printf "%b" " ${CYN}Compiling ${YLW}${PACKAGE}${RST}... " mkdir -p "${LFS}/sources/log/chapter${CHAPTER}/" + # shellcheck source=/dev/null source "${LFS}/sources/chapter${CHAPTER}/${PACKAGE}.sh" 2>&1 > "${LFS}/sources/log/chapter${CHAPTER}/${PACKAGE}.log" 2>&1 & pid=$! spinner "$pid" "${SPINNER}" retval=$? |