mirror of
https://gitlab.archlinux.org/tpowa/archboot.git
synced 2024-09-20 03:50:37 +02:00
shellcheck fixes
This commit is contained in:
parent
a5e0612a6e
commit
6835d1c652
1 changed files with 4 additions and 4 deletions
|
@ -168,7 +168,7 @@ _zram_usr() {
|
||||||
USR_SYMLINKS="bin local lib lib64"
|
USR_SYMLINKS="bin local lib lib64"
|
||||||
fi
|
fi
|
||||||
for i in ${USR_SYMLINKS}; do
|
for i in ${USR_SYMLINKS}; do
|
||||||
/usr.zram/bin/sln /usr.zram/${i} /usr/${i}
|
/usr.zram/bin/sln /usr.zram/"${i}" /usr/"${i}"
|
||||||
done
|
done
|
||||||
# pacman kills symlinks in below /usr
|
# pacman kills symlinks in below /usr
|
||||||
# mount --bind is the only way to solve this.
|
# mount --bind is the only way to solve this.
|
||||||
|
@ -256,10 +256,10 @@ _kver_x86() {
|
||||||
_kver_generic() {
|
_kver_generic() {
|
||||||
# get kernel version from installed kernel
|
# get kernel version from installed kernel
|
||||||
if [[ -f "/${VMLINUZ}" ]]; then
|
if [[ -f "/${VMLINUZ}" ]]; then
|
||||||
reader=cat
|
reader="cat"
|
||||||
# try if the image is gzip compressed
|
# try if the image is gzip compressed
|
||||||
[[ $(file -b --mime-type "/${VMLINUZ}") == 'application/gzip' ]] && reader=zcat
|
[[ $(file -b --mime-type "/${VMLINUZ}") == 'application/gzip' ]] && reader="zcat"
|
||||||
read _ _ kver _ < <($reader "/${VMLINUZ}" | grep -m1 -aoE 'Linux version .(\.[-[:alnum:]]+)+')
|
read -r _ _ HWKVER _ < <($reader "/${VMLINUZ}" | grep -m1 -aoE 'Linux version .(\.[-[:alnum:]]+)+')
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# fallback if no detectable kernel is installed
|
# fallback if no detectable kernel is installed
|
||||||
|
|
Loading…
Reference in a new issue