Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Configure bash to use nala wrapper instead of apt #67

Merged
merged 6 commits into from Apr 3, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 40 additions & 0 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -79,5 +79,45 @@ sudo nala install brave-browser -y
systemctl enable sddm
systemctl set-default graphical.target

# Configure bash to use nala wrapper instead of apt
ubashrc="/home/$username/.bashrc"
rbashrc="/root/.bashrc"
if [ -f "$ubashrc" ]; then
echo '
apt() {
command nala "$@"
}
sudo() {
if [ "$1" = "apt" ]; then
shift
command sudo nala "$@"
else
command sudo "$@"
fi
}' | tee -a "$ubashrc" > /dev/null
fi

if [ -f "$rbashrc" ]; then
echo '
apt() {
command nala "$@"
}
sudo() {
if [ "$1" = "apt" ]; then
shift
command sudo nala "$@"
else
command sudo "$@"
fi
}' | tee -a "$rbashrc" > /dev/null
fi

# Beautiful bash
git clone https://github.com/ChrisTitusTech/mybash
cd mybash
bash setup.sh
cd $builddir

# Polybar configuration
bash scripts/changeinterface