From 5989e71fafe33d5a36e061fc0ddc810a716cda5b Mon Sep 17 00:00:00 2001 From: koalaman Date: Sun, 16 Aug 2015 17:51:52 -0700 Subject: [PATCH] Created SC1090 (markdown) --- SC1090.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 SC1090.md diff --git a/SC1090.md b/SC1090.md new file mode 100644 index 0000000..c051404 --- /dev/null +++ b/SC1090.md @@ -0,0 +1,20 @@ +## This source will be skipped since it's not constant. + +### Problematic code: + + source "$1/lib.sh" + +### Correct code: + + # shellcheck disable=SC1090 + source "$1/lib.sh" + +### Rationale: + +ShellCheck is not able to include sourced files from non-constant paths. + +Instead, be aware that anything in the sourced file will be ignored, and then disable the message. + +### Exceptions: + +Ignore the message with a [[directive]]. \ No newline at end of file