mirror of
https://github.com/Xevion/dotfiles.git
synced 2026-01-31 04:24:10 -06:00
Add chcode editor alias
This commit is contained in:
@@ -16,6 +16,11 @@ alias l='ls -CF'
|
|||||||
# https://docs.gitignore.io/install/command-line
|
# https://docs.gitignore.io/install/command-line
|
||||||
function gi() { curl -sL https://www.toptal.com/developers/gitignore/api/$@ ;}
|
function gi() { curl -sL https://www.toptal.com/developers/gitignore/api/$@ ;}
|
||||||
|
|
||||||
|
function chcode() {
|
||||||
|
EDITOR="code --wait"
|
||||||
|
chezmoi edit $1
|
||||||
|
}
|
||||||
|
|
||||||
# Add an "alert" alias for long running commands. Use like so:
|
# Add an "alert" alias for long running commands. Use like so:
|
||||||
# sleep 10; alert
|
# sleep 10; alert
|
||||||
alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"'
|
alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"'
|
||||||
|
|||||||
Reference in New Issue
Block a user