bash syntax highlighting issue with heredocs

31 views
Skip to first unread message

Nirk Niggler

unread,
Mar 21, 2013, 12:46:10 AM3/21/13
to vim...@googlegroups.com
Looking at vim 7.3 filetype.vim:

" Vim support file to detect file types
"
" Maintainer: Bram Moolenaar <****@***.***>
" Last Change: 2010 Jul 30


This is valid bash:

#!/bin/bash
head -n 3 <<FOOBAR | cat
1
2
3
4
5
FOOBAR

The output is:

1
2
3


The script (with the shebang line) is available at http://hastebin.com/rusoculipo.bash

The syntax highlighting treats the "| cat" part of the command to be a string (as if the heredoc starts from the <<), but it should be considered part of the pipeline.

Christian Brabandt

unread,
Mar 21, 2013, 3:01:58 AM3/21/13
to vim...@googlegroups.com
Hi Nirk!
This should go to the maintainer of the syntax script, that is mentioned
at the top of the syntax/sh.vim file (in your runtime directory).

regards,
Christian
--
Ob Hamster, Biber oder Maus, McDonald's macht 'nen BigMac draus.

Nirk Niggler

unread,
Mar 21, 2013, 9:43:46 AM3/21/13
to vim...@googlegroups.com, br...@vim.org
Christian:

Thanks for a quick response. I provided the file header, and the
maintainer is Bram.

Under any other circumstance, I would direct my message to the
appropriate person. But we are talking about Bram, and I imagine by
now he would have outsourced maintenance of vim files to other people.

- Nirk

On Thu, Mar 21, 2013 at 3:01 AM, Christian Brabandt <cbl...@256bit.org> wrote:
> Hi Nirk!
>
> --
> --
> You received this message from the "vim_dev" 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 a topic in the Google Groups "vim_dev" group.
> To unsubscribe from this topic, visit https://groups.google.com/d/topic/vim_dev/C8zhEctybeg/unsubscribe?hl=en.
> To unsubscribe from this group and all its topics, send an email to vim_dev+u...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>

James McCoy

unread,
Mar 21, 2013, 10:04:17 AM3/21/13
to vim_dev


On Mar 21, 2013 9:43 AM, "Nirk Niggler" <nirk.n...@gmail.com> wrote:
>
> Christian:
>
> Thanks for a quick response.  I provided the file header, and the
> maintainer is Bram.

Bram maintains filetype.vim, but not syntax/sh.vim which is where the syntax highlighting for bash is defined. That's maintained by Charles Campbell.

Reply all
Reply to author
Forward
0 new messages