From eef65ada81d180858dc96d18412696b3c98d531e Mon Sep 17 00:00:00 2001 From: koalaman Date: Sat, 8 Feb 2014 14:20:16 -0800 Subject: [PATCH] Created SC1078 (markdown) --- SC1078.md | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 SC1078.md diff --git a/SC1078.md b/SC1078.md new file mode 100644 index 0000000..6a8770c --- /dev/null +++ b/SC1078.md @@ -0,0 +1,29 @@ +# Did you forget to close this double quoted string? + +### Problematic code: + + greeting="hello + target="world" + +### Correct code: + + greeting="hello" + target="world" + +### Rationale: + +The first line is missing a quote. + +ShellCheck warns when it detects multi-line double quoted, single quoted or backticked strings when the character that follows it looks out of place. + +### Contraindications + +If you do want a multiline variable, just make sure the character after it is a quote, space or line feed. + + var='multiline + 'value + +is more readable and won't produce a warning as: + + var='multiline + value'