mirror of
https://github.com/sheerun/vim-polyglot.git
synced 2025-11-09 12:03:53 -05:00
Allow to configure python syntax, #474
This commit is contained in:
56
config.vim
56
config.vim
@@ -1,41 +1,47 @@
|
|||||||
if !exists('g:markdown_enable_spell_checking')
|
function! s:SetDefault(name, value)
|
||||||
let g:markdown_enable_spell_checking = 0
|
if !exists(a:name)
|
||||||
end
|
let {a:name} = a:value
|
||||||
|
endif
|
||||||
|
endfunction
|
||||||
|
|
||||||
if !exists('g:markdown_enable_input_abbreviations')
|
call s:SetDefault('g:markdown_enable_spell_checking', 0)
|
||||||
let g:markdown_enable_input_abbreviations = 0
|
call s:SetDefault('g:markdown_enable_input_abbreviations', 0)
|
||||||
end
|
call s:SetDefault('g:markdown_enable_mappings', 0)
|
||||||
|
|
||||||
if !exists('g:markdown_enable_mappings')
|
|
||||||
let g:markdown_enable_mappings = 0
|
|
||||||
end
|
|
||||||
|
|
||||||
" Enable jsx syntax by default
|
" Enable jsx syntax by default
|
||||||
if !exists('g:jsx_ext_required')
|
call s:SetDefault('g:jsx_ext_required', 0)
|
||||||
let g:jsx_ext_required = 0
|
|
||||||
endif
|
|
||||||
|
|
||||||
" Make csv loading faster
|
" Make csv loading faster
|
||||||
if !exists('g:csv_start')
|
call s:SetDefault('g:csv_start', 1)
|
||||||
let g:csv_start = 1
|
call s:SetDefault('g:csv_end', 2)
|
||||||
endif
|
|
||||||
if !exists('g:csv_end')
|
|
||||||
let g:csv_end = 2
|
|
||||||
endif
|
|
||||||
|
|
||||||
" Disable json concealing by default
|
" Disable json concealing by default
|
||||||
if !exists('g:vim_json_syntax_conceal')
|
call s:SetDefault('g:vim_json_syntax_conceal', 0)
|
||||||
let g:vim_json_syntax_conceal = 0
|
|
||||||
endif
|
|
||||||
|
|
||||||
let g:filetype_euphoria = 'elixir'
|
call s:SetDefault('g:filetype_euphoria', 'elixir')
|
||||||
|
|
||||||
|
call s:SetDefault('g:python_highlight_builtins', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_builtin_objs', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_builtin_types', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_builtin_funcs', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_builtin_funcs_kwarg', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_exceptions', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_string_formatting', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_string_format', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_string_templates', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_indent_errors', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_space_errors', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_doctests', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_func_calls', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_class_vars', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_operators', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_file_headers_as_comments', 1)
|
||||||
|
call s:SetDefault('g:python_slow_sync', 1)
|
||||||
|
|
||||||
augroup filetypedetect
|
augroup filetypedetect
|
||||||
autocmd BufNewFile,BufReadPost *.vb setlocal filetype=vbnet
|
autocmd BufNewFile,BufReadPost *.vb setlocal filetype=vbnet
|
||||||
augroup END
|
augroup END
|
||||||
|
|
||||||
let g:python_highlight_all = 1
|
|
||||||
|
|
||||||
augroup filetypedetect
|
augroup filetypedetect
|
||||||
if v:version < 704
|
if v:version < 704
|
||||||
" NOTE: this line fixes an issue with the default system-wide lisp ftplugin
|
" NOTE: this line fixes an issue with the default system-wide lisp ftplugin
|
||||||
|
|||||||
@@ -1,41 +1,47 @@
|
|||||||
if !exists('g:markdown_enable_spell_checking')
|
function! s:SetDefault(name, value)
|
||||||
let g:markdown_enable_spell_checking = 0
|
if !exists(a:name)
|
||||||
end
|
let {a:name} = a:value
|
||||||
|
endif
|
||||||
|
endfunction
|
||||||
|
|
||||||
if !exists('g:markdown_enable_input_abbreviations')
|
call s:SetDefault('g:markdown_enable_spell_checking', 0)
|
||||||
let g:markdown_enable_input_abbreviations = 0
|
call s:SetDefault('g:markdown_enable_input_abbreviations', 0)
|
||||||
end
|
call s:SetDefault('g:markdown_enable_mappings', 0)
|
||||||
|
|
||||||
if !exists('g:markdown_enable_mappings')
|
|
||||||
let g:markdown_enable_mappings = 0
|
|
||||||
end
|
|
||||||
|
|
||||||
" Enable jsx syntax by default
|
" Enable jsx syntax by default
|
||||||
if !exists('g:jsx_ext_required')
|
call s:SetDefault('g:jsx_ext_required', 0)
|
||||||
let g:jsx_ext_required = 0
|
|
||||||
endif
|
|
||||||
|
|
||||||
" Make csv loading faster
|
" Make csv loading faster
|
||||||
if !exists('g:csv_start')
|
call s:SetDefault('g:csv_start', 1)
|
||||||
let g:csv_start = 1
|
call s:SetDefault('g:csv_end', 2)
|
||||||
endif
|
|
||||||
if !exists('g:csv_end')
|
|
||||||
let g:csv_end = 2
|
|
||||||
endif
|
|
||||||
|
|
||||||
" Disable json concealing by default
|
" Disable json concealing by default
|
||||||
if !exists('g:vim_json_syntax_conceal')
|
call s:SetDefault('g:vim_json_syntax_conceal', 0)
|
||||||
let g:vim_json_syntax_conceal = 0
|
|
||||||
endif
|
|
||||||
|
|
||||||
let g:filetype_euphoria = 'elixir'
|
call s:SetDefault('g:filetype_euphoria', 'elixir')
|
||||||
|
|
||||||
|
call s:SetDefault('g:python_highlight_builtins', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_builtin_objs', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_builtin_types', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_builtin_funcs', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_builtin_funcs_kwarg', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_exceptions', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_string_formatting', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_string_format', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_string_templates', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_indent_errors', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_space_errors', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_doctests', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_func_calls', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_class_vars', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_operators', 1)
|
||||||
|
call s:SetDefault('g:python_highlight_file_headers_as_comments', 1)
|
||||||
|
call s:SetDefault('g:python_slow_sync', 1)
|
||||||
|
|
||||||
augroup filetypedetect
|
augroup filetypedetect
|
||||||
autocmd BufNewFile,BufReadPost *.vb setlocal filetype=vbnet
|
autocmd BufNewFile,BufReadPost *.vb setlocal filetype=vbnet
|
||||||
augroup END
|
augroup END
|
||||||
|
|
||||||
let g:python_highlight_all = 1
|
|
||||||
|
|
||||||
augroup filetypedetect
|
augroup filetypedetect
|
||||||
if v:version < 704
|
if v:version < 704
|
||||||
" NOTE: this line fixes an issue with the default system-wide lisp ftplugin
|
" NOTE: this line fixes an issue with the default system-wide lisp ftplugin
|
||||||
|
|||||||
Reference in New Issue
Block a user