- Break long lines on
|
,&&
, or||
and indent the continuations. - Don't add an extension to executable shell scripts.
- Don't put a line break before
then
ordo
, useif ...; then
andwhile ...; do
. - Use
for x; do
, notfor x in "$@"; do
. - Use
snake_case
for variable names andALLCAPS
for environment variables. - Use single quotes for strings that don't contain escapes or variables.
- Use two-space indentation.
This repository has been archived by the owner on Dec 15, 2023. It is now read-only.