aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMahmoud Al-Qudsi <mqudsi@neosmart.net>2017-09-27 13:38:24 -0500
committerJustin M. Keyes <justinkz@gmail.com>2018-01-30 21:12:49 +0100
commit5d2dd2ebe28c31f223d77355a8f9d40adfb41c82 (patch)
tree05285ed29c5b2d678cda737d2ae03b2fd80debef /src
parent8728a5d50bc3339db81c7f29d59c55f9f817f06c (diff)
downloadrneovim-5d2dd2ebe28c31f223d77355a8f9d40adfb41c82.tar.gz
rneovim-5d2dd2ebe28c31f223d77355a8f9d40adfb41c82.tar.bz2
rneovim-5d2dd2ebe28c31f223d77355a8f9d40adfb41c82.zip
win: has("wsl") on Windows Subsystem for Linux #7330
Per CMAKE docs, CMAKE_HOST_SYSTEM_VERSION is the result of `uname -r`: https://cmake.org/cmake/help/v3.4/variable/CMAKE_HOST_SYSTEM_VERSION.html?highlight=uname A numeric version string for the system. On systems that support uname, this variable is set to the output of uname -r. On other systems this is set to major-minor version numbers. On Windows it is something like "6.1", so it won't match ".*-Microsoft". Closes #7329
Diffstat (limited to 'src')
-rw-r--r--src/nvim/eval.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/nvim/eval.c b/src/nvim/eval.c
index 07a9e9286d..67538c248e 100644
--- a/src/nvim/eval.c
+++ b/src/nvim/eval.c
@@ -10671,6 +10671,9 @@ static void f_has(typval_T *argvars, typval_T *rettv, FunPtr fptr)
"windows",
"winaltkeys",
"writebackup",
+#if defined(HAVE_WSL)
+ "wsl",
+#endif
"nvim",
};