This commit is contained in:
hl 2024-11-19 14:00:25 +08:00
parent 7f1cf9a54b
commit 53df72f761
4 changed files with 18 additions and 1 deletions

View File

@ -7,6 +7,8 @@ AWD=$(dirname "$SCRIPT")
DISTRO_PVE=$((command -v pvesh &>/dev/null && echo 1) || echo 0)
configure(){
echo -e "APT::Install-Recommends "0";
APT::Install-Suggests "0";" | tee /etc/apt/apt.conf.d/01norecommend >/dev/null
sed -i "s/.*Host \*.*/Host \*/g" /etc/ssh/ssh_config
sed -i "/.*HashKnownHosts.*/d" /etc/ssh/ssh_config
sed -i "/.*HostKeyAlgorithms.*/d" /etc/ssh/ssh_config

View File

@ -69,6 +69,20 @@ main(){
curl $SET_AUTH $SET_PROXY -SfLo source_pkg.tar.$ext "$dl_url"
tar -xvf source_pkg.tar.$ext >/dev/null
dirname=$(rev <<< "$pkgname" | cut -d '.' -f 3- | rev)
elif (echo $ext | grep -i deb) &>/dev/null; then
if command -v dpkg &>/dev/null; then
curl $SET_AUTH $SET_PROXY -SfLo source_pkg.deb "$dl_url"
dpkg -i source_pkg.deb
echo "Install Complete!"
popd >/dev/null
rm -rf "$tmp_dir"
exit 0
else
echo "Not Debian System"
popd >/dev/null
rm -rf "$tmp_dir"
exit 1
fi
else
echo "Unknown format: $pkgname"
popd >/dev/null

View File

@ -4,4 +4,4 @@ command="nala"
command -v $command &>/dev/null || command="apt"
$command update
fd="$1"
sed "s/ /\n/g" $fd | awk '!/^ *(#|$)/' "$1" | xargs -r $command install -y
sed "s/ /\n/g" $fd | awk '!/^ *(#|$)/' "$1" | xargs -r $command install --no-install-recommends -y

View File

@ -5,6 +5,7 @@ tcpdump
unrar
unzip
rsync
micro
ripgrep
fd-find
exa