V8.00.000.2025.06.17
All checks were successful
🛡️ Shell Script Linting / 🛡️ Shell Script Linting (push) Successful in 56s
All checks were successful
🛡️ Shell Script Linting / 🛡️ Shell Script Linting (push) Successful in 56s
Signed-off-by: Marc S. Weidner <msw@coresecret.dev>
This commit is contained in:
@@ -23,24 +23,8 @@ check_pkgs() {
|
||||
### Declare Arrays, HashMaps, and Variables.
|
||||
# shellcheck disable=SC2154
|
||||
declare -A hmp_tool_pkg=(
|
||||
[apt-show-versions]="apt-show-versions"
|
||||
[bc]="bc"
|
||||
[dig]="bind9-dnsutils"
|
||||
[host]="bind9-dnsutils"
|
||||
[hexdump]="bsdmainutils"
|
||||
[btrfs]="btrfs-progs"
|
||||
[bunzip2]="bzip2"
|
||||
[setupcon]="console-setup"
|
||||
[base64]="coreutils"
|
||||
[cat]="coreutils"
|
||||
[chmod]="coreutils"
|
||||
[chown]="coreutils"
|
||||
[cp]="coreutils"
|
||||
[echo]="coreutils"
|
||||
[ln]="coreutils"
|
||||
[mkdir]="coreutils"
|
||||
[curl]="curl"
|
||||
[dirmngr]="dirmngr"
|
||||
[dmsetup]="dmsetup"
|
||||
[fsck.vfat]="dosfstools"
|
||||
[mkfs.vfat]="dosfstools"
|
||||
@@ -55,34 +39,19 @@ check_pkgs() {
|
||||
[gdisk]="gdisk"
|
||||
[grep]="grep"
|
||||
[gzip]="gzip"
|
||||
[haveged]="haveged"
|
||||
[update-initramfs]="initramfs-tools"
|
||||
[ip]="iproute2"
|
||||
[ping]="iputils-ping"
|
||||
[jq]="jq"
|
||||
[loadkeys]="kbd"
|
||||
[setfont]="kbd"
|
||||
[modprobe]="kmod"
|
||||
[logrotate]="logrotate"
|
||||
[lsb_release]="lsb-release"
|
||||
[parted]="parted"
|
||||
[chpasswd]="passwd"
|
||||
[chsh]="passwd"
|
||||
[lspci]="pciutils"
|
||||
[sysctl]="procps"
|
||||
[pwgen]="pwgen"
|
||||
[sed]="sed"
|
||||
[sudo]="sudo"
|
||||
[tar]="tar"
|
||||
[tree]="tree"
|
||||
[unzip]="unzip"
|
||||
[blkid]="util-linux"
|
||||
[dmesg]="util-linux"
|
||||
[lsblk]="util-linux"
|
||||
[findmnt]="util-linux"
|
||||
[mount]="util-linux"
|
||||
[umount]="util-linux"
|
||||
[xxd]="vim-common"
|
||||
[wget]="wget"
|
||||
[whois]="whois"
|
||||
[zsh]="zsh"
|
||||
@@ -110,7 +79,7 @@ check_pkgs() {
|
||||
# shellcheck disable=SC2312
|
||||
mapfile -t ary_unique_pkgs < <(printf '%s\n' "${ary_missing_pkgs[@]}" | sort -u)
|
||||
do_log "debug" "file_only" "0030() [ary_unique_pkgs]='${ary_unique_pkgs[*]}'."
|
||||
apt-get install -y --no-install-recommends --no-install-suggests "${ary_unique_pkgs[*]}" 2>&1
|
||||
apt-get install -y --no-install-recommends --no-install-suggests "${ary_unique_pkgs[*]}" >| "${DIR_LOG}/0030_check_pkgs.log"
|
||||
|
||||
fi
|
||||
|
||||
@@ -118,14 +87,14 @@ check_pkgs() {
|
||||
if grep -RqsE '^[[:space:]]*deb .*backports' /etc/apt/sources.list /etc/apt/sources.list.d; then
|
||||
# shellcheck disable=SC2155
|
||||
declare codename=$(lsb_release -sc)
|
||||
apt-get install -y -t "${codename}-backports" debootstrap
|
||||
apt-get install -y -t "${codename}-backports" debootstrap >> "${DIR_LOG}/0030_check_pkgs.log"
|
||||
else
|
||||
apt-get install -y debootstrap
|
||||
apt-get install -y debootstrap >> "${DIR_LOG}/0030_check_pkgs.log"
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ -z "$(command -v dialog || true)" ]]; then
|
||||
if ! "${VAR_AUTO_INSTALL}"; then apt-get install -y --no-install-recommends dialog; fi
|
||||
if ! "${VAR_AUTO_INSTALL}"; then apt-get install -y --no-install-recommends dialog >> "${DIR_LOG}/0030_check_pkgs.log"; fi
|
||||
fi
|
||||
|
||||
guard_dir && return 0
|
||||
|
||||
Reference in New Issue
Block a user