This commit is contained in:
darkclip 2026-01-10 08:20:06 +08:00
parent 4f99bf5a90
commit 8cea394ad0
Signed by: hl
GPG Key ID: A948B2AA5A5D3BDB
2 changed files with 6 additions and 12 deletions

View File

@ -58,17 +58,12 @@ personalize() {
usage(){
echo "Usage: $0 [OPTIONS]";
echo "OPTIONS:";
echo " -n no install";
echo " -p personalize only";
}
DO_INSTALL=true;
DO_SYS_CONFIG=true;
while getopts ":np" OPT; do
case $OPT in
n)
DO_INSTALL=false;
;;
p)
DO_SYS_CONFIG=false;
;;
@ -82,4 +77,4 @@ done;
if $DO_SYS_CONFIG; then
configure
fi
personalize $DO_INSTALL
personalize

11
init.sh
View File

@ -9,6 +9,9 @@ case $OS_CODE in
bookworm) OS_VERSION="12" ;;
Trixie) OS_VERSION="13" ;;
esac
if [ -z $OS_VERSION ]; then
echo "Unsupported Debian Code: $OS_CODE" && exit 1
fi
DISTRO_PVE=$((command -v pvesh &>/dev/null && echo 1) || echo 0)
SCRIPT=$(readlink -f "$0")
@ -101,11 +104,7 @@ config(){
apt list nala ca-certificates curl gnupg gpg lsb-release git zsh | awk -F'/' '/\// {print $1}' | xargs -r apt install --no-install-recommends -y
set_pkg_source
apt update
if $1; then
$AWD/configure.sh
else
$AWD/configure.sh -n
fi
$AWD/configure.sh
}
usage(){
@ -139,7 +138,7 @@ while getopts ":f:cm:" OPT; do
esac;
done;
config $DO_INSTALL
config
if $DO_INSTALL; then
$AWD/install.sh $PKG_BASE
fi