super-linter: Shellcheck Configuration File Ignored

Describe the bug

Without -x shellcheck won’t open any files that may be referenced but not explicitly passed to it on the command line. This is problematic, because super-linter invokes shellcheck once per file.

Expected behavior

I expected shellcheck not to complain simply because I sourced one script from another.

Steps to Reproduce

  1. Create a bash script that sources another bash script.
  2. Run super linter.

Logs

SC1091: Not following: <filename>: openBinaryFile: does not exist (No such file or directory)

For more information:
  https://www.shellcheck.net/wiki/SC1091 -- Not following: <filename>: open...

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Reactions: 1
  • Comments: 36 (15 by maintainers)

Commits related to this issue

Most upvoted comments

Until that is implemented, there’s very little we can do, unfortunately. The workaround described in https://github.com/github/super-linter/issues/1633#issuecomment-997220963 should at least mitigate this issue.

After org name changed, correct link is this https://github.com/super-linter/super-linter/issues/1633#issuecomment-997220963

TLDR: Add .shellcheckrc file to your repo https://github.com/super-linter/super-linter/blob/main/TEMPLATES/.shellcheckrc