summaryrefslogtreecommitdiff
path: root/autoload
diff options
context:
space:
mode:
authorw0rp <devw0rp@gmail.com>2017-11-04 10:46:19 +0000
committerw0rp <devw0rp@gmail.com>2017-11-04 10:46:19 +0000
commit9c0a5635df6b3d5241f424ab4bfea2817ba89ddc (patch)
tree060d2e39443f8e0c3bce475b00a20f3427e169f1 /autoload
parent9010458581c4a69f6c987830254391d9c041b236 (diff)
downloadale-9c0a5635df6b3d5241f424ab4bfea2817ba89ddc.zip
#1081 Remove the ale#python#IsExecutable function
Diffstat (limited to 'autoload')
-rw-r--r--autoload/ale/fixers/autopep8.vim2
-rw-r--r--autoload/ale/fixers/isort.vim2
-rw-r--r--autoload/ale/fixers/yapf.vim2
-rw-r--r--autoload/ale/python.vim8
4 files changed, 4 insertions, 10 deletions
diff --git a/autoload/ale/fixers/autopep8.vim b/autoload/ale/fixers/autopep8.vim
index e0e6205f..e2dd7bfe 100644
--- a/autoload/ale/fixers/autopep8.vim
+++ b/autoload/ale/fixers/autopep8.vim
@@ -12,7 +12,7 @@ function! ale#fixers#autopep8#Fix(buffer) abort
\ ['autopep8'],
\)
- if !ale#python#IsExecutable(l:executable)
+ if !executable(l:executable)
return 0
endif
diff --git a/autoload/ale/fixers/isort.vim b/autoload/ale/fixers/isort.vim
index ddd95611..00d968f4 100644
--- a/autoload/ale/fixers/isort.vim
+++ b/autoload/ale/fixers/isort.vim
@@ -11,7 +11,7 @@ function! ale#fixers#isort#Fix(buffer) abort
\ ['isort'],
\)
- if !ale#python#IsExecutable(l:executable)
+ if !executable(l:executable)
return 0
endif
diff --git a/autoload/ale/fixers/yapf.vim b/autoload/ale/fixers/yapf.vim
index b15e481e..ba7453b8 100644
--- a/autoload/ale/fixers/yapf.vim
+++ b/autoload/ale/fixers/yapf.vim
@@ -11,7 +11,7 @@ function! ale#fixers#yapf#Fix(buffer) abort
\ ['yapf'],
\)
- if !ale#python#IsExecutable(l:executable)
+ if !executable(l:executable)
return 0
endif
diff --git a/autoload/ale/python.vim b/autoload/ale/python.vim
index 4734ac44..2a15f454 100644
--- a/autoload/ale/python.vim
+++ b/autoload/ale/python.vim
@@ -74,12 +74,6 @@ function! ale#python#FindVirtualenv(buffer) abort
return $VIRTUAL_ENV
endfunction
-" Run an executable check for Python scripts.
-" On Windows, 1 will be returned if the file is merely readable.
-function! ale#python#IsExecutable(path) abort
- return executable(a:path)
-endfunction
-
" Given a buffer number and a command name, find the path to the executable.
" First search on a virtualenv for Python, if nothing is found, try the global
" command. Returns an empty string if cannot find the executable
@@ -96,7 +90,7 @@ function! ale#python#FindExecutable(buffer, base_var_name, path_list) abort
\ join([l:virtualenv, s:bin_dir, l:path], s:sep)
\)
- if ale#python#IsExecutable(l:ve_executable)
+ if executable(l:ve_executable)
return l:ve_executable
endif
endfor