None of the languages parsed by the sh plugin support prettier pragma directives, preventing the use of requirePragma.
Adding support would involve adding a hasPragma method with the signature (string) => boolean to the sh parser definition that is used by all added languages. It's probably "good enough" to parse the file, get the first statement, and check the first comment for the pragma content.
None of the languages parsed by the sh plugin support prettier pragma directives, preventing the use of
requirePragma
.Adding support would involve adding a
hasPragma
method with the signature(string) => boolean
to thesh
parser definition that is used by all added languages. It's probably "good enough" to parse the file, get the first statement, and check the first comment for the pragma content.