diff --git a/SC1103.md b/SC1103.md index 9094f4b..9892a51 100644 --- a/SC1103.md +++ b/SC1103.md @@ -3,7 +3,8 @@ ### Problematic code: ```sh -#!/bin/zsh +# shellcheck shell=zsh +export PAGER=less ``` ### Correct code: @@ -11,7 +12,8 @@ Any supported shell on the shebang or the `-s` option ```sh -#!/bin/sh +# shellcheck shell=sh +export PAGER=less ``` ### Rationale: @@ -27,4 +29,11 @@ The supported shell types are listed in the help context, at the moment these ar * sh * bash * dash -* ksh \ No newline at end of file +* ksh + +### Related resources: + +- Similar rules + - [[SC1008]] - unrecognized shebang + - [[SC1071]] - unsupported shebang +- [[Documentation for shell directive|Directive#shell]]