Created: 2017 October 11th
Updated: 2020 August 27thEdit this page on GitHub
chsh utility to change your default shell:
1# list out the shells available with -l2chsh -l3# if that doesn't work try4cat /etc/shells5# /bin/bash6# /bin/zsh7# /bin/fish8# set the default shell (with -s) to fish9chsh -s /bin/fish10# set the default shell (with -s) to zsh11chsh -s /bin/zsh
List any process running on port 8000
Output will look similar to this.
1COMMAND PID USER2chrome 16085 iamuser
Then kill it with
1kill -9 16085
1# open your bash_profile with nano2nano ~/.bash_profile3# add your alias4alias f='fish'5# ctrl+x then y to save
You may find that commands like
ll are under your
if not then add the following as an alias:
1ls -lart | sort -k9,9
If you need to set the permission on a file (with
chmod) but don’t
know what the permissions of similar files are like you can use
stat, the following command displays the permissions of the contents
1stat -c "%a %n" ~/.ssh/*
Tired of having to enter your SSH password each time you want to do a git operation?
Add the following to your
1# nano ~/.bashrc2[ -z "$SSH_AUTH_SOCK" ] && eval "\$(ssh-agent -s)"
Want to search for an entry in your Bash history?
Ctrl+r then enter your search term.
Accidentally added your password as a bash command?
To remove that from the bash history:
1# list out history with2history
Then take the number from the output:
1471 ssh-agent2472 exit3473 kill 531114474 super secret password5475 history
Then delete the line you want removed:
1history -d 474
history again and gone until you do it again.
This will move everything in the Downloads folder to the Videos folder including any folders inside Downloads.
1mv ~/Downloads/* ~/Videos