Created
February 17, 2020 07:04
-
-
Save aiafrasinei/b00878679445f08ef9121d9ca4f65f8f to your computer and use it in GitHub Desktop.
linux shell
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
change to previous working directory: | |
cd - | |
cd $OLDPWD | |
backup file: | |
cp file{,.bak} | |
change file extension: | |
mv file{.old,.new} | |
ssh into remote computer: | |
ssh-keygen | |
ssh-copy-id remote-host | |
programs listening on ports: | |
netstat -nutlp | |
command substitution: | |
$ VAR=`command` | |
$ VAR=$(command) | |
automatically answer yes to any commands: | |
yes | command |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment