Adding a PwdChanged hook for autocmds

2011-12-10 Thread Rich Healey
I attempted to add a new hook to the autocmd subsystem to allow me to bind actions to the current working directory changing. Attached is my attempt, I also tried patching ex_cd in desperation while it wasn't working. I think my issue is in the way I'm invoking apply_autocmds, but this seems to b

Re: Adding a PwdChanged hook for autocmds

2011-12-11 Thread Bram Moolenaar
Rich Healey wrote: > I attempted to add a new hook to the autocmd subsystem to allow me to bind > actions to the current working directory changing. > > Attached is my attempt, I also tried patching ex_cd in desperation while it > wasn't working. I think my issue is in the way I'm invoking > app

Re: Adding a PwdChanged hook for autocmds

2011-12-11 Thread Rich Healey
I'm not completely sure I understand, (Please forgive my ignorance) the caller of vim_chdir should not be obviously aware of the existance of the hook surely? The actions take place just before returning. Obviously the user adding a hook to PwdChanged that attempts to invoke :chdir would proble

Re: Adding a PwdChanged hook for autocmds

2011-12-11 Thread Kent Sibilev
On Sun, Dec 11, 2011 at 8:51 AM, Rich Healey wrote: > I'm not completely sure I understand, (Please forgive my ignorance) the > caller of vim_chdir should not be obviously aware of the existance of the > hook surely? The actions take place just before returning. > > Obviously the user adding a hoo