How to disable visual mode on mouse select for vim
If selecting text with the mouse in vi enters visual mode, it can cause copy-and-paste problems. To prevent visual mode, create or edit vi ~/.vimrc and add set…
11 articles on this topic
If selecting text with the mouse in vi enters visual mode, it can cause copy-and-paste problems. To prevent visual mode, create or edit vi ~/.vimrc and add set…
There are several ways to convert uppercase strings to lowercase in Bash: tr, awk, Bash 4.0 expansion, or Perl.
Use date with -d in Bash to display yesterday's date or an earlier date.
A small Bash shell tip: remove trailing spaces, leading spaces, or both from a variable with sed.
Shell techniques for counting blank and nonblank lines in a file, useful in scripts and troubleshooting.
How to redirect standard output and standard error to a log file. Correct syntax: command > /path/to/log 2>&1. This redirects stdout to the log and stderr to stdout.
An overview of if/else statements in Bash scripts and comparison conditions. Basic if syntax: if [ condition ] then ... fi.
If testing a shell script produces [: =: unary operator expected error, check the if condition on the reported line to see whether the variable has a value and whether the code…
On UNIX or Linux, you can extract selected files or directories from a tarball without first extracting everything. This is more convenient and saves space…
Managing output is a common task in Linux. Commands often redirect errors and output to files so they can be stored and inspected later, especially commands…
One advantage of Bash is auto-completion, which saves typing every character of a command or filename. This article covers two ways to disable it…