mirror of
https://github.com/koalaman/shellcheck.git
synced 2025-10-03 19:29:44 +08:00
Updated SC1042 (markdown)
24
SC1042.md
24
SC1042.md
@@ -1,4 +1,22 @@
|
||||
Found 'eof' further down, but not on a separate line.
|
||||
Close matches include '-eof' (!= 'eof').
|
||||
# Close matches include '-eof' (!= 'eof').
|
||||
|
||||
See companion error [[SC1041]].
|
||||
## Problematic code:
|
||||
|
||||
```bash
|
||||
#!/bin/bash
|
||||
cat <<-eof
|
||||
Hello World
|
||||
-eof
|
||||
```
|
||||
|
||||
## Correct code:
|
||||
|
||||
```bash
|
||||
#!/bin/bash
|
||||
cat <<-eof
|
||||
Hello World
|
||||
eof
|
||||
```
|
||||
|
||||
## Rationale:
|
||||
See companion error [[SC1041]]. This error occurs at the same time it.
|
Reference in New Issue
Block a user