53 lines
1.1 KiB
Bash
53 lines
1.1 KiB
Bash
#!/bin/zsh
|
|
|
|
# Raine's .zshrc
|
|
|
|
if [ "$PROFILEINC" = "1" ]; then
|
|
. ~/.profile
|
|
fi
|
|
|
|
export EDITOR=vim
|
|
export GPG_TTY=$(tty)
|
|
export PATH="$PATH:$HOME/.yarn/bin:$HOME/.config/yarn/global/node_modules/.bin:$HOME/.local/bin"
|
|
|
|
# oh-my-zsh init
|
|
if [ -f "$HOME/.oh-my-zsh/oh-my-zsh.sh" ]; then
|
|
export ZSH="$HOME/.oh-my-zsh"
|
|
ZSH_THEME="afowler"
|
|
plugins=(git docker docker-compose node zsh-autosuggestions zsh-syntax-highlighting zsh-cargo-completion)
|
|
source $ZSH/oh-my-zsh.sh
|
|
else
|
|
echo "oh-my-zsh not detected :("
|
|
PS1="$(whoami)@${HOSTNAME:-$(hostname)} $ "
|
|
fi
|
|
|
|
update_dotfiles() {
|
|
cd $HOME/.dotfiles
|
|
git pull
|
|
cd - &> /dev/null
|
|
}
|
|
|
|
share_cdn() {
|
|
if ! [ -f "$1" ]; then
|
|
echo "file needs to exist"
|
|
return 1
|
|
fi
|
|
scp $1 keymaker:/usr/share/cdn/random/$2 > /dev/null
|
|
echo "https://cdn.ixvd.net/random/${2:-$(basename $1)}"
|
|
}
|
|
|
|
container() {
|
|
docker run \
|
|
-ti \
|
|
--rm \
|
|
--name tmp-$(id -u)-$(openssl rand -hex 8) \
|
|
--network ${CONTAINER_NETWORK:-internal} \
|
|
alpine \
|
|
ash
|
|
}
|
|
|
|
[ -f "$HOME/.config/i3/shortcuts-i3.sh" ] && . ~/.config/i3/shortcuts-i3.sh
|
|
|
|
alias q="exit"
|
|
alias vim="nvim"
|
|
alias vi="nvim"
|