]> git.phdru.name Git - dotfiles.git/blobdiff - .vim/ftplugin/python.vim
.vim/ftplugin/python.vim: Fix elseif syntax
[dotfiles.git] / .vim / ftplugin / python.vim
index 75f2e51334b8c4a7b4f75282a625ce67f3ad6cc3..95333e6f57c50e17a8768bff14d08f1cdc99be45 100644 (file)
@@ -32,18 +32,15 @@ function! SavePython()
    let ext = expand("%:e")
    if ext == "pyem"
       return
-   elif ext == "ptl"
+   elseif ext == "ptl"
       !compyle-ptl %
    else
       !compyle %
       if ext != "py"
          !rm -f %[co]
       endif
-      if executable(expand('%:p')) || !executable('chmod')
-        return
-      endif
       if getline(1) =~ "^#!"
-         !chmod +x %
+         call SetExecutableBit(1)
       endif
    endif
 endfunction