fixed install so that it accepts arguments like -s for silent (only in pika scripts)
This commit is contained in:
parent
ff2b5afb49
commit
18ebe57291
1 changed files with 7 additions and 2 deletions
|
@ -1,3 +1,4 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
packages=(
|
packages=(
|
||||||
"colorscript"
|
"colorscript"
|
||||||
"docker"
|
"docker"
|
||||||
|
@ -20,7 +21,11 @@ _help() {
|
||||||
}
|
}
|
||||||
|
|
||||||
_install_func() {
|
_install_func() {
|
||||||
curl -fsSL "https://git.k4li.de/scripts/installs/raw/branch/main/${1}.sh" | { bash || sh }
|
if [ -n "$2" ]; then
|
||||||
|
curl -fsSL "https://git.k4li.de/scripts/installs/raw/branch/main/${1}.sh" | { bash -s -- "$2" || sh -s -- "$2" }
|
||||||
|
else
|
||||||
|
curl -fsSL "https://git.k4li.de/scripts/installs/raw/branch/main/${1}.sh" | { bash || sh }
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
_check() {
|
_check() {
|
||||||
|
@ -43,7 +48,7 @@ _install() {
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
if _check; then
|
if _check; then
|
||||||
_install_func "$1"
|
_install_func "$1" "$2"
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue