vim.command() always throw exception after KeyboardInterrupt

2013-10-17 Thread Yggdroot Chen
I encounter a critical issue when writing vim script using python, for example the code is as below: def func(): try: while 1: xxx xxx except KeyboardInterrupt: pass vim.command("") I press ctrl-c to interrupt the program, after Keyboa

Re: vim.command() always throw exception after KeyboardInterrupt

2013-10-17 Thread Yggdroot Chen
在 2013年10月17日星期四UTC+8下午9时54分53秒,Ben Fritz写道: > On Thursday, October 17, 2013 5:14:36 AM UTC-5, Yggdroot Chen wrote: > > > I encounter a critical issue when writing vim script using python, for > > example the code is as below: > > > > > > > > &g

Re: vim.command() always throw exception after KeyboardInterrupt

2013-10-17 Thread Yggdroot Chen
在 2013年10月17日星期四UTC+8下午10时11分28秒,ZyX写道: > On Oct 17, 2013 5:50 PM, "Yggdroot Chen" wrote: > > > > I encounter a critical issue when writing vim script using python, for > > example the code is as below: > > > > def func(): > >     try: > >  

Re: vim.command() always throw exception after KeyboardInterrupt

2013-10-17 Thread Yggdroot Chen
在 2013年10月18日星期五UTC+8上午12时10分12秒,Ben Fritz写道: > On Thursday, October 17, 2013 10:08:19 AM UTC-5, Yggdroot Chen wrote: > > > 在 2013年10月17日星期四UTC+8下午9时54分53秒,Ben Fritz写道: > > > > The issue is you're trying to prevent the user from rescuing their Vim > > &g

Re: vim.command() always throw exception after KeyboardInterrupt

2013-10-17 Thread Yggdroot Chen
在 2013年10月17日星期四UTC+8下午6时14分36秒,Yggdroot Chen写道: > I encounter a critical issue when writing vim script using python, for > example the code is as below: > > > > def func(): > > try: > > while 1: > > xxx > >

Re: vim.command() always throw exception after KeyboardInterrupt

2013-10-18 Thread Yggdroot Chen
在 2013年10月18日星期五UTC+8下午11时12分52秒,ZyX写道: > > now I redescribe my issue, I want to do some cleanup actions after ctrl-c > > is pressed. the code is as below: > > def func(): > > try: > > while 1: > > xxx > > xxx > > except KeyboardInterrupt: > >

Re: selective increment numbers in substitute

2013-10-23 Thread Yggdroot Chen
在 2013年10月7日星期一UTC+8下午9时00分38秒,Yosi Izaq写道: > Hi, > > I want to selectively increment numbers in substitute. > I'm familiar w/ submatch for increment all numbers in substitute, like in > vis. mode range: > '<,'>s/\d\+/\=submatch(0)+1/gc > > But what if I want to increment numbers only of lines c

Re: vim.command() always throw exception after KeyboardInterrupt

2013-10-23 Thread Yggdroot Chen
在 2013年10月19日星期六UTC+8上午1时01分43秒,ZyX写道: > On Friday, October 18, 2013 7:12:52 PM UTC+4, ZyX wrote: > > > now I redescribe my issue, I want to do some cleanup actions after ctrl-c > > > is pressed. the code is as below: > > > def func(): > > > try: > > > while 1: > > >

how to omit vim's error message when writing script using python?

2013-11-26 Thread Yggdroot Chen
for example: try: vim.eval("match('aaa','\{')") except vim.error: pass error message E866&E64 can still be displayed. is it a bug? -- -- 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

how to omit vim's error message when writing script using python?

2013-11-26 Thread Yggdroot Chen
for example: try: vim.eval("match('aaa','\{')") except vim.error: pass error message E866&E64 can still be displayed. is it a bug? -- -- 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

syn match aaa '[' report error, is it a bug?

2013-11-27 Thread Yggdroot Chen
If I want to highlight '[', I have to write like this: syn match aaa '\[' but as a pattern, '[' can match '['. I think it's a bug! -- -- 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:/

bug report about python

2014-01-14 Thread Yggdroot Chen
try: while 1: vim.command('let a=1') except KeyboardInterrupt: vim.command('bd') "this line is the root cause vim will be dead when is pressed. vim7.4, python3, maybe python2 is the same. -- -- You received this message from the "vim_use" maillist. Do not top-post! Type your reply belo

Re: bug report about python

2014-01-15 Thread Yggdroot Chen
在 2014年1月15日星期三UTC+8下午1时45分22秒,Yggdroot Chen写道: > try: > while 1: > vim.command('let a=1') > except KeyboardInterrupt: > vim.command('bd') "this line is the root cause > > vim will be dead when is pressed. > vim7.4, python3, maybe pyth

Re: bug report about python

2014-01-16 Thread Yggdroot Chen
在 2014年1月16日星期四UTC+8上午4时58分33秒,Bram Moolenaar写道: > Yggdroot Chen wrote: > > > > > try: > > > while 1: > > > vim.command('let a=1') > > > except KeyboardInterrupt: > > > vim.command('bd') "this line is

Re: Speed up find command

2014-01-16 Thread Yggdroot Chen
在 2014年1月17日星期五UTC+8上午3时51分41秒,Marcin Bednarek写道: > Hello, > > In .vimrc I have the following lines: > > set path=** > set suffixesadd=.php > set wildmode=longest,list > set wildmenu > set > wildignore+=tmp\*,*.swp,*.zip,*.exe,*\.settings\*,\.classpath,\.project,*.class,\.springBeans,bin\*,targe

[bug] getchar(0) should not return `<80>^B`

2016-06-05 Thread Yggdroot Chen
execute the following commands: :set nomore :while 1|sleep 1|echo getchar(0)|endw if input the key , the output will be: <80>^B<80>, <80>^B<80>. <80>^B <80>^B <80>^B <80>^B ... I think the output should be <80>^B<80>, <80>^B<80>. 0 0 0 ... There

Re: [bug] getchar(0) should not return `<80>^B`

2016-06-05 Thread Yggdroot Chen
在 2016年6月6日星期一 UTC+8下午12:35:25,Yggdroot Chen写道: > execute the following commands: > :set nomore > :while 1|sleep 1|echo getchar(0)|endw > > if input the key , the output will be: > <80>^B<80>, > <80>^B<80>. > <80>^B > <80

Re: Unknown option argument: "--multiprocessing-fork"

2016-06-21 Thread Yggdroot Chen
在 2014年12月23日星期二 UTC+8下午6:32:05,Canis Major写道: > I have an error on Windows vim version 7.4.417: Unknown option argument: > "--multiprocessing-fork" . It is related to using python > multiprocessing. How I can fix that? Same issue here on Windows vim version 7.4.1923. It's not related to any plu

Re: Vim and Python 3.7

2018-07-10 Thread Yggdroot Chen
在 2018年7月2日星期一 UTC+8下午9:54:21,Yongwei Wu写道: > I am using MacVim with Homebrew. Homebrew's Python version is now 3.7, and > executing simply `pyx print('Hello')` gives me a warning message: > > the imp module is deprecated in favour of importlib … > > > ​I guess this should not be specific to Ma

How to handle the E143 error?

2018-12-04 Thread Yggdroot Chen
:h e143 it says: WARNING: Using autocommands is very powerful, and may lead to unexpected side effects. Be careful not to destroy your text. So it's an unexpected error, this is no way to handle it? -- -- You received this message from the "vim_use" maillist. Do not top-post! Type your reply b

Re: How to handle the E143 error?

2018-12-05 Thread Yggdroot Chen
在 2018年12月5日星期三 UTC+8下午4:10:42,Christian Brabandt写道: > On Di, 04 Dez 2018, Yggdroot Chen wrote: > > > :h e143 > > it says: > > WARNING: Using autocommands is very powerful, and may lead to unexpected > > side > > effects. Be careful not to destroy your text.

Re: Vim plugin with Python3

2019-07-31 Thread Yggdroot Chen
https://github.com/Yggdroot/LeaderF -- -- 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 Goog