summaryrefslogtreecommitdiff
path: root/.config/aliases
blob: 0ef5d22e93e75c3a2462814dc37fd61c033d0c8d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
#!/bin/sh

alias ..="cd .."
alias ...="cd ../../"

alias reload="source $HOME/.bash_profile"
alias rld="reload"

alias vim="nvim"
alias sudo='doas'
alias sudoedit='doasedit'

alias q='exit'
alias c='clear'
alias t='todo.sh'
alias nf='pfetch'

alias ls='exa'
alias lh="exa -1dI '.|..' .*"
alias lt='exa -T'
alias l='exa -la'

alias gs='git status'
alias ga='git add'
alias gu='git add -u'
alias df='git diff'
alias lg='git log --oneline --decorate --all --graph'

alias config="git --git-dir=$HOME/.cfg/ --work-tree=$HOME"
alias cs='config status'
alias ca='config add' 
alias cu='config add -u'
alias cdf='config diff'
alias clg='config log --oneline --decorate --all --graph'

alias shrc="nvim $HOME/.bashrc"
alias vars="nvim $HOME/.bash_profile"
alias wmrc="nvim $XDG_CONFIG_HOME/i3/config"
alias vimrc="cd $XDG_CONFIG_HOME/nvim; nvim"
alias initrc="nvim $XDG_CONFIG_HOME/X11/xinitrc"
alias barconf="nvim $XDG_CONFIG_HOME/polybar/config.ini"
alias aliases="nvim $XDG_CONFIG_HOME/aliases"

alias mixer="pulsemixer"
alias weather="curl wttr.in/$(cat $HOME/.config/forecast/location)"

_completion_loader git
_completion_loader exa
_completion_loader todo.sh
_completion_loader sudo

complete -o bashdefault -o default -o nospace -F __git_wrap__git_main config
complete -o bashdefault -o default -F _fzf_path_completion vim
complete -o bashdefault -o filenames -F _exa ls
complete -F _todo t
complete -F _sudo doas

function fzf () { 
    command fzf --color=$(<$XDG_CONFIG_HOME/scheme/fzf-color) "$@"; 
}; 
export -f fzf