----------------------------------------------------------------------------------
@MSGID: 1@dont-email.me> 88aedd43
@REPLY: 1@dont-email.me> 6682eb3e
@REPLYADDR Janis Papanagnou
<janis_papanagnou+ng@hotmail.com>
@REPLYTO 2:5075/128 Janis Papanagnou
@CHRS: CP866 2
@RFC: 1 0
@RFC-Message-ID: 1@dont-email.me>
@RFC-References: 1@dont-email.me>
1@nnrp.usenet.blueworldhosting.com> 1@dont-email.me> <rzk79m.8tugqn@bdesham.net>
1@dont-email.me> 1@dont-email.me> 1@dont-email.me>
@TZUTC: 0200
@PID: Mozilla/5.0 (X11; Linux x86_64; rv:45.0)
Gecko/20100101 Thunderbird/45.8.0
@TID: FIDOGATE-5.12-ge4e8b94
On 20.09.2023 20:47, Janis Papanagnou wrote:
> On 20.09.2023 14:50, castAway wrote:
>>> [ awk syntax within ksh syntax highlighting ]
>>
>> Check `:h sh-awk`:
>> [...]
>> file into $HOME/.vim/after/syntax/sh/awkembed.vim: >
>>
>> [code]
>>
>> This code will then let the awk code in the single quotes: >
>> awk `...awk code here...`
>> be highlighted using the awk highlighting syntax. Clearly this may be
>> extended to other languages.
>> [...]
>
> Thanks! :-)
Upthread I noted I have problems with new ksh syntax constructs, e.g.
in (( count++ )) the final closing parenthesis is market as error.
This was the primary concern of my (original) post.
The suggestion was - granted, it`s a kludge - to set syntax to `zsh`
(instead of `sh`). This changed the coloring slightly but it worked
as as far as such constructs were not any more marked as errors. Fine.
The awkembed.vim suggestion now doesn`t work correctly with the other
syntax issue; now either awk programs have a correct coloring but I
see those spurious syntax errors (with syntax=sh and awkembed.vim) or
I see no spurious errors but the whole awk program is uncolored (with
syntax=zsh).
It would be nice to have a solution that works correctly for both
requirements.
I tried to install a $HOME/.vim/after/syntax/zsh/awkembed.vi for zsh
but obviously this is not how this is supposed to work.
Any idea or how to fix both issues reliably (not just one or the other)?
Janis
--- Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0
* Origin: A noiseless patient Spider (2:5075/128)
SEEN-BY: 5001/100 5005/49 5015/255 5019/40 5020/715
848 1042 4441 12000
SEEN-BY: 5030/49 1081 5075/128
@PATH: 5075/128 5020/1042 4441