Updated SC2206 (markdown)

koalaman
2017-04-02 14:27:32 -07:00
parent 1f1324fabc
commit 04ba5e2811

@@ -41,7 +41,7 @@ You are expanding a variable unquoted in an array. This will invoke the shell's
Instead, prefer explicitly splitting (or not splitting): Instead, prefer explicitly splitting (or not splitting):
* If the variable should become a single array element, quote it. * If the variable should become a single array element, quote it.
* If you want to split into lines or words, use `mapfile`, `read -ra` and/or `while` loops appropriate. * If you want to split into lines or words, use `mapfile`, `read -ra` and/or `while` loops as appropriate.
This prevents the shell from doing unwanted splitting and glob expansion, and therefore avoiding problems with data containing spaces or special characters. This prevents the shell from doing unwanted splitting and glob expansion, and therefore avoiding problems with data containing spaces or special characters.