From 6a44faff66b326bd9ce300591962b9eb8c6dd8af Mon Sep 17 00:00:00 2001 From: Vidar Holen Date: Wed, 30 Dec 2020 20:01:54 -0800 Subject: [PATCH] Created SC2275 (markdown) --- SC2275.md | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 SC2275.md diff --git a/SC2275.md b/SC2275.md new file mode 100644 index 0000000..2c7542c --- /dev/null +++ b/SC2275.md @@ -0,0 +1,28 @@ +## Command name starts with =. Bad line break? + +### Problematic code: + +```sh +my_variable + =value +``` + +### Correct code: + +```sh +myvariable=value +``` + +### Rationale: + +ShellCheck found a command name starting with a `=`. This was likely not meant as a new command, but instead a continuation from a previous line. + +Make sure the `=` is used correctly. + +### Exceptions: + +None, though you can quote the value to make ShellCheck ignore it, e.g. `"=foo"`. + +### Related resources: + +* Help by adding links to BashFAQ, StackOverflow, man pages, POSIX, etc! \ No newline at end of file