We use `au FileChangedShell <buffer>` syntax
instead of `au FileChangedShell fname`.
if executable('chmod')
function! SetExecutableBit(x)
checktime
if executable('chmod')
function! SetExecutableBit(x)
checktime
- let fname = expand("%:p")
- let fx = executable(fname)
+ let fx = executable(expand("%:p"))
execute "au FileChangedShell <buffer> call _BufChangedCB()"
if a:x && !fx
!chmod a+x %
execute "au FileChangedShell <buffer> call _BufChangedCB()"
if a:x && !fx
!chmod a+x %