zerog

[archived] simple Parabola GNU/Linux post-install script
git clone git://git.hanetzok.net/zerog
Log | Files | Refs | README | LICENSE

commit f993b3ef173fef4426bf03f0464a3d0633a63915
parent 7841eb371e361cdc83c6a9e1f8a996839d5ddc27
Author: Markus Hanetzok <markus@hanetzok.net>
Date:   Wed, 17 Aug 2022 23:41:54 +0200

Download script collection via Git

Diffstat:
Mzerog | 14++++++++++++++
1 file changed, 14 insertions(+), 0 deletions(-)

diff --git a/zerog b/zerog @@ -6,6 +6,7 @@ script_dir="$(dirname "$(realpath $0)")" name="$(logname)" progs="$script_dir/progs.list" dotfiles="git://cybvik.xyz/dotfiles" +scripts="git://cybvik.xyz/scripts" src="/home/$name/.local/src" giturl="git://cybvik.xyz" logfile="/tmp/zerog.log" @@ -53,6 +54,15 @@ get_dotfiles() { sudo -u "$name" cp -rfT /tmp/dotfiles "/home/$name" >/dev/null 2>&1 } +get_scripts() { + printf "### Download script collection ###\n" + sudo -u "$name" git clone "$scripts" "/tmp/scripts" >/dev/null 2>&1 || + { warning "Could not clone scripts"; return 1; } + sudo -u "$name" mkdir -p "/home/$name/.local/bin" + sudo -u "$name" cp -rfT /tmp/scripts/* "/home/$name/.local/bin/"\ + >/dev/null 2>&1 +} + suckless() { [ -d "$src" ] || sudo -u "$name" mkdir -p "$src" printf "### Installing suckless software ###\n" @@ -104,6 +114,10 @@ get_dotfiles && task_complete "get_dotfiles()" || error "Could not install dotfiles" +get_scripts && + task_complete "get_scripts()" || + error "Could not download scripts" + suckless && task_complete "suckless()" || error "Could not install suckless programs"