Skip to content

Cooperate with ShellCheck extension #19

@KlfJoat

Description

@KlfJoat

Hi. I really appreciate this extension and how much easier it makes Bats test writing. Thank you so much for creating and maintaining it!

I use another VSC extension, timonwong.shellcheck, to lint my Bash code with ShellCheck. Both ShellCheck and that extension support linting Bats files.

However, the ShellCheck extension only lints files that have the "ShellScript" language identifier. And your wonderful extension creates a new configured language identifier, "Bats (Bash Automated Testing System)". So timonwong.shellcheck won't run on Bats files while your extension is enabled.

When I want to lint my Bats files, I disable your extension, manually set the individual file as a ShellScript, then fix issues. I have 45 Bats files in this project so far, and it's barely an eighth completed.

I opened an issue for this with them, thinking a fix was on their side. But they pointed out that they have an API for other extensions to interface with. https://github.com/vscode-shellcheck/vscode-shellcheck/blob/master/doc%2FAPI.md

It seems like the way for Bats language support to be enabled and linted by ShellCheck is if you could please hook into their API. I'd help if I could, but I tend to write bash scripts, not javascript extensions so I'm not sure how much help I could be beyond beta testing.

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions