Set configs for different envrionments
+ Check if we're in docker or running xorg + Adjust tmux / vim settings
This commit is contained in:
@@ -1,14 +1,23 @@
|
||||
# For Rust stuff, uncomment this line
|
||||
#. "$HOME/.cargo/env"
|
||||
|
||||
# Clear kscreen cached settings
|
||||
alias kapp-kscreen='rm -rf ~/.local/share/kscreen/*'
|
||||
# Restart plasmashell
|
||||
alias kapp-plasmashell='sudo pkill plasmashell && plasmashell --replace &> /dev/null &'
|
||||
# Clear swap
|
||||
alias kapp-swap='sudo swapoff -a && sudo swapon -a'
|
||||
alias kapp-git='git config --global user.name "Shaun Reed" && git config --global user.email "shaunrd0@gmail.com"'
|
||||
alias kapp-update='sudo apt update -y && sudo apt upgrade -y && sudo apt upgrade --fix-broken --fix-missing --auto-remove'
|
||||
if [ -f /.dockerenv ]; then
|
||||
export DOT_PACKAGES='git stow vim tmux ranger clang wget curl'
|
||||
alias kapp-update='apt update -y && apt upgrade -y && apt upgrade --fix-broken --fix-missing --auto-remove'
|
||||
alias kapp-init='apt update -y && apt install $DOT_PACKAGES -y'
|
||||
alias kapp-swap='swapoff -a && swapon -a'
|
||||
else
|
||||
export DOT_PACKAGES='git stow vim xsel xclip tmux ranger clang yakuake wget curl'
|
||||
alias kapp-update='sudo apt update -y && sudo apt upgrade -y && sudo apt upgrade --fix-broken --fix-missing --auto-remove'
|
||||
alias kapp-init='sudo apt update -y && sudo apt install $DOT_PACKAGES'
|
||||
# Clear kscreen cached settings
|
||||
alias kapp-kscreen='rm -rf ~/.local/share/kscreen/*'
|
||||
# Restart plasmashell
|
||||
alias kapp-plasmashell='sudo pkill plasmashell && plasmashell --replace &> /dev/null &'
|
||||
alias kapp-swap='sudo swapoff -a && sudo swapon -a'
|
||||
alias kapp-vbox='ps aux www |grep 'VBoxClient --draganddrop' | awk '{print $2}' | xargs kill'
|
||||
fi
|
||||
|
||||
# Alias / export customizations
|
||||
|
||||
@@ -85,3 +94,12 @@ export LESS='--mouse --wheel-lines 2'
|
||||
# + -#2 to shift 2 columns horizontally when right / left arrow is pressed
|
||||
export LESS="$LESS -R -w -#2"
|
||||
|
||||
|
||||
if ! [ command -v conda &>/dev/null ] && [ -e ~/Code/Clones/mambaforge/bin/conda ] && ! grep -e conda ~/.bashrc &>/dev/null; then
|
||||
if ! (~/Code/Clones/mambaforge/bin/conda init | awk -F "==>" '{print $1}'); then
|
||||
echo "[dot] ERROR: Failed to initialize Conda."
|
||||
fi
|
||||
echo "[dot] WARN: Ran \`conda init\`; Conda was installed but not initialized"
|
||||
source ~/.bashrc
|
||||
fi
|
||||
|
||||
|
||||
Reference in New Issue
Block a user