diff --git a/usr/lib/archboot/cpio.sh b/usr/lib/archboot/cpio.sh index 5e6ce16ac..5b9b43fb2 100644 --- a/usr/lib/archboot/cpio.sh +++ b/usr/lib/archboot/cpio.sh @@ -6,7 +6,7 @@ # no long options support in archboot parseopts() { - local opt='' optarg='' i='' shortopts="$1" + local opt='' i='' shortopts="$1" local -a unused_argv=() shift shift @@ -287,7 +287,7 @@ add_file() { add_file "$srcrealpath" "$srcrealpath" "$mode" else if [[ -n $mode ]]; then - command chmod "$mode" ${BUILDROOT}${dest} + command chmod "$mode" "${BUILDROOT}${dest}" fi fi fi @@ -371,7 +371,7 @@ initialize_buildroot() { } run_build_hook() { - local hook="$1" script='' resolved='' + local hook="$1" script='' # shellcheck disable=SC2034 local MODULES=() BINARIES=() FILES=() SCRIPT='' # find script in install dirs diff --git a/usr/lib/archboot/iso.sh b/usr/lib/archboot/iso.sh index a9dea7f1f..bf184c79f 100644 --- a/usr/lib/archboot/iso.sh +++ b/usr/lib/archboot/iso.sh @@ -66,12 +66,12 @@ _prepare_kernel_initramfs_files() { fi if [[ -f "./init-${_ARCH}.img" ]]; then echo "Using existing init-${_ARCH}.img..." - cp ./init-${_ARCH}.img ${_ISODIR}/boot/ + cp "./init-${_ARCH}.img" "${_ISODIR}/boot/" else echo "Preparing init-${_ARCH}.img..." archboot-cpio.sh -c "/etc/archboot/${_ARCH}-init.conf" -k "${ALL_kver}" -g "${_ISODIR}/boot/init-${_ARCH}.img" || exit 1 # save init ramdisk for further images - cp ${_ISODIR}/boot/init-${_ARCH}.img ./ + cp "${_ISODIR}/boot/init-${_ARCH}.img" ./ fi echo "Preparing initramfs-${_ARCH}.img..." #shellcheck disable=SC2154 @@ -80,7 +80,7 @@ _prepare_kernel_initramfs_files() { if grep -qw 'archboot' /etc/hostname; then if [[ -d "${_CACHEDIR}" ]]; then echo "Removing ${_CACHEDIR}..." - rm -rf ${_CACHEDIR} + rm -rf "${_CACHEDIR}" fi fi }