aboutsummaryrefslogtreecommitdiffstats
path: root/lua
diff options
context:
space:
mode:
authorRasmus Michelsen <RMichelsen@protonmail.com>2020-09-05 22:14:40 +0200
committerThomas Vigouroux <tomvig38@gmail.com>2020-09-06 13:42:24 +0200
commit07c0e837ab8e9bec41dcfc59b63b5e80703659a8 (patch)
treeda8f3cd3b67370255fcbe2ceec8c821fee393cd3 /lua
parentAdded changes (diff)
downloadnvim-treesitter-07c0e837ab8e9bec41dcfc59b63b5e80703659a8.tar
nvim-treesitter-07c0e837ab8e9bec41dcfc59b63b5e80703659a8.tar.gz
nvim-treesitter-07c0e837ab8e9bec41dcfc59b63b5e80703659a8.tar.bz2
nvim-treesitter-07c0e837ab8e9bec41dcfc59b63b5e80703659a8.tar.lz
nvim-treesitter-07c0e837ab8e9bec41dcfc59b63b5e80703659a8.tar.xz
nvim-treesitter-07c0e837ab8e9bec41dcfc59b63b5e80703659a8.tar.zst
nvim-treesitter-07c0e837ab8e9bec41dcfc59b63b5e80703659a8.zip
Fixed win32 check hopefully
Diffstat (limited to 'lua')
-rw-r--r--lua/nvim-treesitter/install.lua12
1 files changed, 6 insertions, 6 deletions
diff --git a/lua/nvim-treesitter/install.lua b/lua/nvim-treesitter/install.lua
index 58abd6fe5..6740a8147 100644
--- a/lua/nvim-treesitter/install.lua
+++ b/lua/nvim-treesitter/install.lua
@@ -72,14 +72,14 @@ local function select_args(repo)
'-Os',
'-lstdc++',
}
- if not fn.has('win32') then
+ if fn.has('win32') == 0 then
table.insert('-fPIC')
end
return args
end
local function select_install_rm_cmd(cache_folder, project_name)
- if fn.has('win32') then
+ if fn.has('win32') == 1 then
local dir = cache_folder ..'\\'.. project_name
return {
cmd = 'cmd',
@@ -98,7 +98,7 @@ local function select_install_rm_cmd(cache_folder, project_name)
end
local function select_mv_cmd(compile_location, parser_lib_name)
- if fn.has('win32') then
+ if fn.has('win32') == 1 then
return {
cmd = 'cmd',
opts = {
@@ -119,7 +119,7 @@ local function run_install(cache_folder, package_path, lang, repo, with_sync)
parsers.reset_cache()
local path_sep = '/'
- if fn.has('win32') then
+ if fn.has('win32') == 1 then
path_sep = '\\'
end
@@ -234,7 +234,7 @@ function M.update(lang)
end
local function select_uninstall_rm_cmd(lang, parser_lib)
- if fn.has('win32') then
+ if fn.has('win32') == 1 then
return {
cmd = 'cmd',
opts = {
@@ -257,7 +257,7 @@ end
function M.uninstall(lang)
local path_sep = '/'
- if fn.has('win32') then
+ if fn.has('win32') == 1 then
path_sep = '\\'
end