[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#1016919: lintian: bash-term-in-posix-shell false positive for `. "$(dirname "$0")/functions.sh"`



Package: lintian
Version: 2.115.2

The following script (approved by `shellcheck -s sh`) causes a false positive warning `bash-term-in-posix-shell`:

    #!/bin/sh
    . "$(dirname "$0")/functions.sh"
    do_something

I: my-test: bash-term-in-posix-shell '. "$(dirname "$0")/functions.sh"' [usr/bin/my-test:2]

Probably the lintian check is misparsing the quotes and the space between `dirname` and `"$0"`, leading it to believe that an argument is being passed to the sourced script (that would be, in fact, a bashism).

Regards,

--
Gioele Barabucci


Reply to: