Sunday, July 14, 2019

Re: awkembed.vim

On Sa, 13 Jul 2019, 'J S' via vim_use wrote:

> (On the subject of syntax highlighting languages embedded in other languages)
>
> I frequently write (bash) shell scripts with embedded AWK scripts, and I've found the awkembed.vim script quite useful. I have it installed at:
>
> ~/.vim/after/syntax/sh/awkembed.vim
>
> And it works quite well. Now, I would like to extend the idea beyond the set of "shell" and "awk".
>
> There are, obviously, two variables here: The enclosing language and the embedded language. As far as I can tell (based on a little Googoling) this has only been done for the one specific combination: shell & awk. Note: :help sh-embed
>
> Specifically, I have an Expect script with embedded AWK. How hard is it going to be to get this to work?
>
> I took a look at the awkembed.vim script - it's mostly greek to me, although I was able to modify it slightly because my awk has a different name than the one assumed by the script.
>
> It'd be nice if someone could tell me either a quick way to make a script to do what I want - or to tell me it can't be done...

Have a look at :h sh-embed for the general principle.

Best,
Christian
--
Ist Windows 98 ein Spiel oder ein Betriebssystem?

Nein, ich finde ein Spiel sollte schon eine Lösung haben.
Ich stecke im 97. Level.

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/20190714132100.GC31610%40256bit.org.
For more options, visit https://groups.google.com/d/optout.

No comments: