Skip to main content

Shell escaping

Special characters must be escaped to prevent the shell from interpreting them as part of the script/command.

Double quotes "..." suppress globbing and shell expansion but still allow command and variable substitutions.

Single quotes '...' suppress all special characters.

Backslashes " \ " suppress only the character following the slash.