Last active
October 21, 2023 02:11
-
-
Save alex-courtis/055d93b7832d7925a29ec0fa5ca2c0bb to your computer and use it in GitHub Desktop.
Collect Neovim Feature Flags
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- :source this file to collect feature flag values and write to has_list.log | |
-- src/nvim/eval/funcs.c | |
local has_list = { | |
"bsd", | |
"linux", | |
"sun", | |
"unix", | |
"win32", | |
"win64", | |
"fname_case", | |
"acl", | |
"autochdir", | |
"arabic", | |
"autocmd", | |
"browsefilter", | |
"byte_offset", | |
"cindent", | |
"cmdline_compl", | |
"cmdline_hist", | |
"cmdwin", | |
"comments", | |
"conceal", | |
"cursorbind", | |
"cursorshape", | |
"dialog_con", | |
"diff", | |
"digraphs", | |
"eval", | |
"ex_extra", | |
"extra_search", | |
"file_in_path", | |
"filterpipe", | |
"find_in_path", | |
"float", | |
"folding", | |
"fork", | |
"gettext", | |
"iconv", | |
"insert_expand", | |
"jumplist", | |
"keymap", | |
"lambda", | |
"langmap", | |
"libcall", | |
"linebreak", | |
"lispindent", | |
"listcmds", | |
"localmap", | |
"mac", | |
"macunix", | |
"osx", | |
"osxdarwin", | |
"menu", | |
"mksession", | |
"modify_fname", | |
"mouse", | |
"multi_byte", | |
"multi_lang", | |
"nanotime", | |
"num64", | |
"packages", | |
"path_extra", | |
"persistent_undo", | |
"profile", | |
"pythonx", | |
"reltime", | |
"quickfix", | |
"rightleft", | |
"scrollbind", | |
"showcmd", | |
"cmdline_info", | |
"shada", | |
"signs", | |
"smartindent", | |
"startuptime", | |
"statusline", | |
"spell", | |
"syntax", | |
"system", | |
"tablineat", | |
"tag_binary", | |
"termguicolors", | |
"termresponse", | |
"textobjects", | |
"timers", | |
"title", | |
"user_commands", | |
"vartabs", | |
"vertsplit", | |
"virtualedit", | |
"visual", | |
"visualextra", | |
"vreplace", | |
"wildignore", | |
"wildmenu", | |
"windows", | |
"winaltkeys", | |
"writebackup", | |
"nvim", | |
-- hardcoded | |
"gui_running", | |
"patch", | |
"ttyin", | |
"ttyout", | |
"multi_byte_encoding", | |
"syntax_items", | |
"clipboard_working", | |
"clipboard", | |
"wsl", | |
"vim_starting", | |
} | |
local log_name = "has_list.log" | |
local log_file = io.open(log_name, "w") | |
if not log_file then | |
print("could not open " .. log_name) | |
return | |
end | |
io.output(log_file) | |
for _, f in ipairs(has_list) do | |
io.write(string.format("%s=%d\n", f, vim.fn.has(f))) | |
end | |
io.close(log_file) | |
print("wrote " .. log_name) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment