Open
Description
I have a bunch of scripts (not least my dotfiles) where I have to deal with both bash and zsh. However whenever I add some zsh syntax, for example [[ -n "${foo[(r)b]}" ]] && echo 'b was found.' || echo 'b was not found.'
, the entire file becomes highlighted as an error.
I guess possible solutions are:
- Support zsh syntax
- Limit the error highlighting to just the affected line
- Recognise a magic comment to ignore issues for a particular line.
The first option sounds like a big rewrite, to the point where it's probably a different project (although supporting both would be really useful as scripts often mingle the two formats).
Unsure if the second and third options are feasible.