Add initial zsh config
This commit is contained in:
parent
8332004631
commit
04048d4fe4
26
.config/zsh/.zshrc-job-rs
Normal file
26
.config/zsh/.zshrc-job-rs
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
# set env vars, path updates, etc
|
||||||
|
[[ -a $HOME/.rs-vars ]] \
|
||||||
|
&& source $HOME/.rs-vars \
|
||||||
|
&& export PATH=$PATH:$HOME/.rd/bin \
|
||||||
|
&& . /usr/local/opt/asdf/libexec/asdf.sh
|
||||||
|
|
||||||
|
# login shortcuts
|
||||||
|
alias assume="source assume"
|
||||||
|
alias login-bunk='aws sso login --profile'
|
||||||
|
alias login-bunk-id-list="grep sso_account_id $HOME/.aws/config"
|
||||||
|
alias login-pulumi-bunk='pulumi login '$PULUMI_LOGIN_TARGET'$(aws sts get-caller-identity --query Account --output text)'
|
||||||
|
|
||||||
|
# git stuff
|
||||||
|
alias git-push-to-develop='git branch -D develop; git checkout -b develop; git push origin develop -uf; git checkout -'
|
||||||
|
alias gpdev='git-push-to-develop'
|
||||||
|
|
||||||
|
# misc shortcuts
|
||||||
|
alias journal="cd $HOMEBOX; $EDITOR .current-journal"
|
||||||
|
alias kra="cd $HOMEBOX/process/kra; open .current_kra"
|
||||||
|
alias gll="cd $DEVDIR/git/lampo/gitlab"
|
||||||
|
alias bet='bundle exec rspec'
|
||||||
|
alias bel='bundle exec standardrb'
|
||||||
|
alias belr='bundle exec rubocop'
|
||||||
|
alias prt='poetry run pytest'
|
||||||
|
alias prl='poetry run black'
|
||||||
|
|
7
.config/zsh/.zshrc-life-system
Normal file
7
.config/zsh/.zshrc-life-system
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
# life system shortcuts
|
||||||
|
alias life-system='cd ~/dbox/life/system; clear; ls'
|
||||||
|
alias goals='clear; sed -n 2,7p ~/dbox/life/system/direction/goals/current-goals.txt'
|
||||||
|
alias note='cd ~/dbox/life/system/tasks/inbox; vim'
|
||||||
|
alias todo='cd ~/dbox/life/system/tasks; vim +5 todo.txt'
|
||||||
|
alias budget="open ~/dbox/life/finance/budget/.current"
|
||||||
|
|
47
.zshrc
Normal file
47
.zshrc
Normal file
@ -0,0 +1,47 @@
|
|||||||
|
# use vim-like control in shell
|
||||||
|
set -o vi
|
||||||
|
|
||||||
|
# env vars
|
||||||
|
export EDITOR='nvim'
|
||||||
|
export HOMEBOX=$HOME'/dbox'
|
||||||
|
export DEVDIR=$HOME'/dev'
|
||||||
|
|
||||||
|
# path updates
|
||||||
|
export PATH=$HOME/.local/bin:$HOME/.local/scripts:$PATH
|
||||||
|
export PATH=$PATH:/opt/homebrew/opt/ccache/libexec
|
||||||
|
|
||||||
|
# executable name overrides
|
||||||
|
alias vim='nvim'
|
||||||
|
|
||||||
|
# shortcuts for common commands
|
||||||
|
alias 3e='echo;echo;echo'
|
||||||
|
alias 12e='3e;3e;3e;3e'
|
||||||
|
alias ls='ls -F'
|
||||||
|
alias cl='clear; '
|
||||||
|
alias cls='clear;ls'
|
||||||
|
|
||||||
|
# git stuff
|
||||||
|
alias gfo='git fetch origin'
|
||||||
|
alias gpo='git pull origin'
|
||||||
|
alias gfpo='git fetch origin; git pull origin'
|
||||||
|
|
||||||
|
# executable renames/paths
|
||||||
|
alias youtube-dl='youtube-dl --write-info-json'
|
||||||
|
|
||||||
|
# misc commands
|
||||||
|
alias pdt='ping -c 4 drinkingtea.net'
|
||||||
|
alias weather='curl wttr.in'
|
||||||
|
alias shrug='echo "¯\\_(ツ)_/¯"'
|
||||||
|
|
||||||
|
[[ -e $HOME/.profile ]] && source $HOME/.profile
|
||||||
|
|
||||||
|
# add machine-specific configs as appropriate
|
||||||
|
[[ -a $HOME/.config/zsh/.zshrc-life-system ]] \
|
||||||
|
&& source $HOME/.config/zsh/.zshrc-life-system
|
||||||
|
|
||||||
|
# TODO: refactor the below so that general dev is separate from rs specific stuff
|
||||||
|
[[ -a $HOME/.config/zsh/.zshrc-job-rs ]] \
|
||||||
|
&& source $HOME/.config/zsh/.zshrc-job-rs
|
||||||
|
alias lintjs='npx prettier --write'
|
||||||
|
export DEVKITARM=/opt/devkitpro/devkitARM
|
||||||
|
. /opt/homebrew/opt/asdf/libexec/asdf.sh # TODO: ensure not duplicated asdf logic
|
@ -40,4 +40,4 @@ copy_file() {
|
|||||||
|
|
||||||
copy_dir .config $HOME/.config
|
copy_dir .config $HOME/.config
|
||||||
copy_dir .local $HOME/.local
|
copy_dir .local $HOME/.local
|
||||||
# copy_file .zxcv $HOME
|
copy_file .zshrc $HOME
|
||||||
|
Loading…
Reference in New Issue
Block a user