Files
linux_config_bash/bashrc.cust
mattiaborsarini 6b7dd340c4 bashrc.cust: Add 'cust-error' function
This is a general error that will be used in other functions.
2021-08-11 14:50:40 +02:00

36 lines
1019 B
Plaintext

# Custom configuration file
# Prompt configuration
PS1="\[\033[0;31m\]\342\224\214\342\224\200\$([[ \$? != 0 ]] && echo \"(\[\033[0;31m\]\342\234\227\[\033[0;31m\])\342\224\200\")[$(if [[ ${EUID} == 0 ]]; then echo '\[\033[01;31m\]root'; else echo '\[\033[0;39m\]\u'; fi)\[\033[01;33m\]@\[\033[01;96m\]\h\[\033[0;31m\]]\342\224\200[\[\033[0;32m\]\w\[\033[0;31m\]]\n\[\033[0;31m\]\342\224\224\342\224\200\342\224\200\342\225\274 \[\033[0m\]\[\e[01;33m\]\\$\[\e[0m\]"
# Attibutes
bind "set completion-ignore-case on"
shopt -s autocd
shopt -s checkjobs
# Variables
export LESSHISTFILE=-
# Aliases
alias c='bat -n'
alias dd='dd status=progress'
alias e='nano'
alias grep='grep --color=auto -i'
alias l='ls'
alias la='ls -A'
alias o='xdg-open'
alias r='rm -fr'
alias repoinit='repo init --no-clone-bundle'
alias reposync='repo sync --force-sync --no-clone-bundle -c --no-tags'
alias sudo='sudo '
alias wget='wget --hsts-file /dev/null'
# Functions
function cust-error {
echo "ERROR: Invalid argument(s)!"
exit 1
}