Split installpackages into root/nonroot

This commit is contained in:
Rob Watson 2021-04-02 22:36:44 +02:00
parent 06f05cb7ed
commit 2571cf92b9
2 changed files with 14 additions and 10 deletions

View File

@ -1,13 +1,13 @@
#!/usr/bin/env bash
#
# Install packages for a new Arch or Manjaro installation. Requires sudo
# install packages for a new arch or manjaro installation. requires sudo
if [[ $EUID > 0 ]]; then
if [[ $euid > 0 ]]; then
echo "requires administrative privileges"
exit 1
fi
pacman -S --needed --noconfirm base-devel \
pacman -s --needed --noconfirm base-devel \
git \
exa \
fzf \
@ -16,11 +16,6 @@ pacman -S --needed --noconfirm base-devel \
bat \
docker \
docker-compose \
ttf-ubuntu-font-family # Ubuntu Mono font for Alacritty
ttf-ubuntu-font-family # ubuntu mono font for alacritty
# https://rustup.rs/
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
source $HOME/.cargo/env
# https://github.com/dandavison/delta#installation
cargo install git-delta
sudo -u $SUDO_USER ./script/installpackagesnonroot

9
script/installpackagesnonroot Executable file
View File

@ -0,0 +1,9 @@
#!/usr/bin/env bash
#
# install nonsudo packages
# https://rustup.rs/
curl --proto '=https' --tlsv1.2 -ssf https://sh.rustup.rs | sh -s -- -y
# https://github.com/dandavison/delta#installation
cargo install git-delta