Skip to content

Instantly share code, notes, and snippets.

@bellerbrock
Last active October 17, 2019 20:42
Show Gist options
  • Save bellerbrock/f8aae3899b6b5d4a1568a500e100cc7d to your computer and use it in GitHub Desktop.
Save bellerbrock/f8aae3899b6b5d4a1568a500e100cc7d to your computer and use it in GitHub Desktop.
Handy general aliases and for working with breedbase docker containers
#breedbase
alias log='tail -f -n 100 /var/log/sgn/error.log'
#docker commands
alias drm='docker stop $(docker ps -qa) && docker rm $(docker ps -qa) && docker image rm $(docker images) && docker volume rm $(docker volume ls)' # && docker ps -a && docker images && docker volume ls'
alias dps='docker ps --format "table {{.Names}}\t{{.Status}}\t{{.Image}}"'
alias dpsa='docker ps -a'
alias dstart='docker start $(docker ps -qa)'
alias dstop='docker stop $(docker ps -qa)'
alias dockx='docker rm $(docker ps -qa)'
alias bbase='docker exec -e COLUMNS="`tput cols`" -e LINES="`tput lines`" -ti breedbase-web bash'
alias bbase-db='docker exec -e COLUMNS="`tput cols`" -e LINES="`tput lines`" -ti breedbase-db bash'
#common commands
alias vi='vim'
alias mkdir='sudo mkdir'
#alias rm='sudo rm'
alias chmod='sudo chmod'
alias chown='sudo chown'
alias touch='sudo touch'
#alias rmdir='sudo rmdir'
alias cp='sudo cp'
alias mv='sudo mv'
#alias echo='sudo echo'
#alias cl='clear'
alias reboot='sudo reboot'
alias webserv='cd /var/www'
#alias x='exit'
#Update/Upgrade/Remove
alias install='sudo apt-get install'
#alias remove='sudo apt-get --purge remove'
alias update='sudo apt-get update'
alias upgrade='sudo apt-get upgrade'
#alias search='apt-cache search'
alias uu='sudo apt-get update -y && sudo apt-get upgrade -y'
#alias uur='sudo apt-get update -y && sudo apt-get upgrade -y && sudo reboot'
alias uucr='sudo apt-get update -y && sudo apt-get upgrade -y && sudo apt-get autoclean && sudo reboot'
#alias uucs='sudo apt-get update -y && sudo apt-get upgrade -y && sudo apt-get autoclean && sudo shutdown -P now'
#alias deb='sudo dpkg -i'
#alias clean='sudo apt-get autoclean'
#alias xterminator='exec terminator -e tmux&'
# ------------------------ #
# General Aliased Commands #
# ------------------------ #
alias ll='ls -larth'
#alias deb='sudo dpkg -i'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment