if has('macunix') let g:godot_executable = '/Applications/Godot.app' endif if has('win32') || has('win32unix') let g:godot_executable = '' endif func! s:godot_settings() abort setlocal tabstop=4 nnoremap rl :GodotRunLast nnoremap rc :GodotRunCurrent nnoremap rr :GodotRun endfunc augroup godot | au! au FileType gdscript call s:godot_settings() augroup end "YCM config if !has_key( g:, 'ycm_language_server' ) let g:ycm_language_server = [] endif let g:ycm_language_server += [ \ { \ 'name': 'godot', \ 'filetypes': ['gdscript'], \ 'project_root_files': ['project.godot'], \ 'port': 6008 \ } \ ] " vim-lsp if get(g:, 'lsp_loaded', 0) == 1 au User lsp_setup \ call lsp#register_server({ \ 'name': 'godot', \ 'tcp': {server_info->'localhost:6008'}, \ 'allowlist': ['gdscript', 'gdscript3'] \ }) endif " ALE config call ale#linter#Define('gdscript', { \ 'name': 'godot', \ 'lsp': 'socket', \ 'address': '127.0.0.1:6008', \ 'project_root': 'project.godot', \ })