Useful aliases and settings for .bashrc

alias chgrp='chgrp --preserve-root'
alias chmod='chmod --preserve-root'
alias chown='chown --preserve-root'

alias grep='grep --colour=auto'

alias ll='ls -l'
alias ls='ls --color=auto'

# Show open ports
alias ports='netstat -tulanp'

# Lookup for process
alias psx='ps auxw | grep '

# History settings
export HISTFILESIZE=20000
export HISTSIZE=10000
shopt -s histappend

# Combine multiline commands into one in history
shopt -s cmdhist

# Ignore duplicates, ls without options and builtin commands
HISTCONTROL=ignoredups
export HISTIGNORE="&:ls:ll:[bf]g:exit"

Leave a Reply

Your email address will not be published. Required fields are marked *