DEV Community

Discussion on: Lazy habits in linux terminal

Collapse
 
voyeg3r profile image
Sérgio Araújo • Edited

Using fasd cd, zsh-autosuggestions and zsh-autopair helped me a lot with complicated paths/commands. A bunch of aliases also helps me a lot, for example, open the last edited file.

 alias lnvim='nvim -c'\'':e#<1'\'

Dealing with clipboard:

alias pbcopy='xclip -selection clipboard'
alias pbpaste='xclip -i -selection clipboard -o'

Some useful functions like:

# Goes to the folder or create it and goes anyway
mkcd () {
    mkdir -pv -p "$@" && cd $_
}

Does a lazy git commit:

gsend () {
    git commit -am "$1" && git push
}