- Wichert Akkerman wrote:
> Previously Bram Moolenaar wrote:Well, perhaps this autocommand would work then:
> > Thus also foo.sh, foo.vim, foo.c, etc.? Sounds a bit unlikely. Please
> > suggest an autocommand that works.
> foo.sh would be an executable. But if someone sticks foo.vim in
> /etc/modutils he/she will have broken his Debian system anyway so I
> don't see why vim can't mis-guess here either (might even be a good
> hint that something is wrong).
au BufNewFile,BufRead /etc/modutils/* if executable(expand(<afile>)) != 1 | setf modconf | endif
Can you try this out?
Kisses may last for as much as, but no more than, five minutes.
[real standing law in Iowa, United States of America]
/// Bram Moolenaar -- Bram@... -- http://www.moolenaar.net \\\
/// Creator of Vim - Vi IMproved -- http://www.vim.org \\\
\\\ Project leader for A-A-P -- http://www.a-a-p.org ///
\\\ Lord Of The Rings helps Uganda - http://iccf-holland.org/lotr.html ///
- Previously Bram Moolenaar wrote:
> au BufNewFile,BufRead /etc/modutils/* if executable(expand(<afile>)) != 1 | setf modconf | endifSeems to work fine.
> Can you try this out?
/wichert@... This space intentionally left occupied \
| wichert@... http://www.wiggy.net/ |
| 1024D/2FA3BC2D 576E 100B 518D 2F16 36B0 2805 3CB8 9250 2FA3 BC2D |