]> git.phdru.name Git - dotfiles.git/blobdiff - .vim/ftplugin/python.vim
Feat(.vim/ftplugin/python.vim): Do not call chmod if not required
[dotfiles.git] / .vim / ftplugin / python.vim
index c2367b661b124378e7aad6b96aea3893bd0c03db..75f2e51334b8c4a7b4f75282a625ce67f3ad6cc3 100644 (file)
@@ -39,6 +39,9 @@ function! SavePython()
       if ext != "py"
          !rm -f %[co]
       endif
+      if executable(expand('%:p')) || !executable('chmod')
+        return
+      endif
       if getline(1) =~ "^#!"
          !chmod +x %
       endif