shell command
Command to the ~./bash_logout so that the history will get cleared when you logout
1 | echo `history -c` >> ~/.bash_logout |
Get the name of the history file
1 | echo "$HISTFILE" |
See the current history
1 | history |
Hide and display the cursor in the shell
1 | # Hide the cursor |
Three ways of multiple line annotation
1 | :<<EOF |
Make file executable
1 | chmod +x <file.name> |
Use math equation in shell script (example)
1 |
|
Enable interpretation of the backslash escapes
1 | echo -e |
Read varable and assign to a variable <variable.name>
1 | read <variable.name> |
vi/vim language and affiliated shortcuts