Why the bufnew not work here?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Why the bufnew not work here?

Zhe Lee
I use
au BufNewFile *.py 0r headerfile/python.header

in my vimrc file . I want to auto add snippet when the python file is create. But it doesn't work, when I use the "gvim newpy.py" command in command prompt. How to fix this?

--
--
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 [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Why the bufnew not work here?

Nikolay Aleksandrovich Pavlov
2017-07-29 18:45 GMT+03:00 Zhe Lee <[hidden email]>:
> I use
> au BufNewFile *.py 0r headerfile/python.header
>
> in my vimrc file . I want to auto add snippet when the python file is create. But it doesn't work, when I use the "gvim newpy.py" command in command prompt. How to fix this?

This looks like something which will not work in many cases: :read is
supplied relative path, but do you have `headerfile/python.header` in
each directory you happen to run Vim from?

It should “work” by throwing E484 error message though. For me it
works, but error message and “Press ENTER” prompt are hidden by
further setup. Check `:messages`.

>
> --
> --
> 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 [hidden email].
> For more options, visit https://groups.google.com/d/optout.

--
--
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 [hidden email].
For more options, visit https://groups.google.com/d/optout.
Loading...