From 701c0e2770d22f04fea297b2c28447cc949f8cc6 Mon Sep 17 00:00:00 2001 From: Vidar Holen Date: Wed, 19 Oct 2022 20:18:04 -0700 Subject: [PATCH] Created SC1043 (markdown) --- SC1043.md | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 SC1043.md diff --git a/SC1043.md b/SC1043.md new file mode 100644 index 0000000..67d7d2f --- /dev/null +++ b/SC1043.md @@ -0,0 +1,28 @@ +## Found EOF further down, but with wrong casing. + +### Problematic code: + +```sh +cat << EOF +Hello World +Eof +``` + +### Correct code: + +```sh +cat << EOF +Hello World +EOF +``` +### Rationale: + +ShellCheck found a here document (`<<`) where the end token is missing. However, the end token appears with different case further down. If this was meant to be the end of the here document, make sure the case matches. + +### Exceptions: + +None. This error is only emitted when the here document is incomplete. + +### Related resources: + +* Help by adding links to BashFAQ, StackOverflow, man pages, POSIX, etc! \ No newline at end of file