LunarVim/lv-config.lua

98 lines
2.8 KiB
Lua
Raw Normal View History

2021-03-26 04:24:05 +01:00
--[[
2021-03-27 06:59:28 +01:00
O is the global options object
2021-03-26 04:24:05 +01:00
2021-03-27 06:59:28 +01:00
Formatters and linters should be
filled in as strings with either
a global executable or a path to
an executable
2021-06-28 07:06:37 +02:00
]] -- THESE ARE EXAMPLE CONFIGS FEEL FREE TO CHANGE TO WHATEVER YOU WANT
2021-04-03 21:59:03 +02:00
-- general
2021-03-27 22:21:52 +01:00
O.auto_complete = true
2021-04-03 22:02:34 +02:00
O.colorscheme = 'lunar'
2021-03-28 03:10:23 +02:00
O.auto_close_tree = 0
O.wrap_lines = false
2021-05-06 08:23:33 +02:00
O.timeoutlen = 100
O.document_highlight = true
O.extras = false
O.leader_key = ' '
2021-03-28 03:10:23 +02:00
2021-06-28 07:46:25 +02:00
-- After changing plugin config it is recommended to run :PackerCompile
2021-06-28 18:45:45 +02:00
O.plugin.hop.active = true
O.plugin.dial.active = true
2021-06-28 08:37:33 +02:00
O.plugin.dashboard.active = true
2021-06-28 18:45:45 +02:00
O.plugin.matchup.active = true
O.plugin.colorizer.active = true
O.plugin.numb.active = true
2021-06-28 07:46:25 +02:00
-- dashboard
-- O.dashboard.custom_header = {""}
-- O.dashboard.footer = {""}
2021-04-15 06:17:48 +02:00
-- if you don't want all the parsers change this to a table of the ones you want
2021-04-03 22:02:34 +02:00
O.treesitter.ensure_installed = "all"
O.treesitter.ignore_install = {"haskell"}
O.treesitter.highlight.enabled = true
2021-04-03 21:59:03 +02:00
2021-06-28 06:36:29 +02:00
O.lang.clang.diagnostics.virtual_text = false
O.lang.clang.diagnostics.signs = false
O.lang.clang.diagnostics.underline = false
2021-04-02 02:32:49 +02:00
2021-03-27 22:21:52 +01:00
-- python
-- add things like O.python.formatter.yapf.exec_path
-- add things like O.python.linter.flake8.exec_path
-- add things like O.python.formatter.isort.exec_path
2021-06-28 06:36:29 +02:00
O.lang.python.formatter = 'yapf'
2021-03-29 17:43:17 +02:00
-- O.python.linter = 'flake8'
2021-06-28 07:06:37 +02:00
O.lang.python.active = true
2021-06-28 06:36:29 +02:00
O.lang.python.isort = true
O.lang.python.autoformat = true
O.lang.python.diagnostics.virtual_text = true
O.lang.python.diagnostics.signs = true
O.lang.python.diagnostics.underline = true
O.lang.python.analysis.type_checking = "off"
O.lang.python.analysis.auto_search_paths = true
O.lang.python.analysis.use_library_code_types = true
2021-03-27 09:06:14 +01:00
2021-03-27 22:21:52 +01:00
-- lua
-- TODO look into stylua
2021-06-28 07:06:37 +02:00
O.lang.lua.active = true
2021-06-28 06:36:29 +02:00
O.lang.lua.formatter = 'lua-format'
2021-03-28 09:52:09 +02:00
-- O.lua.formatter = 'lua-format'
2021-06-28 06:36:29 +02:00
O.lang.lua.autoformat = false
2021-03-27 01:28:08 +01:00
2021-03-27 22:21:52 +01:00
-- javascript
2021-06-28 06:36:29 +02:00
O.lang.tsserver.formatter = 'prettier'
O.lang.tsserver.linter = nil
O.lang.tsserver.autoformat = true
2021-03-28 09:52:09 +02:00
-- json
2021-06-28 06:36:29 +02:00
O.lang.json.autoformat = true
2021-03-28 09:58:56 +02:00
2021-04-27 06:59:23 +02:00
-- ruby
2021-06-28 06:36:29 +02:00
O.lang.ruby.autoformat = true
2021-05-25 00:01:24 +02:00
-- go
2021-06-28 06:36:29 +02:00
O.lang.go.autoformat = true
2021-03-28 09:58:56 +02:00
-- create custom autocommand field (This would be easy with lua)
-- Turn off relative_numbers
-- O.relative_number = false
-- Turn off cursorline
-- O.cursorline = false
-- Neovim turns the default cursor to 'Block'
-- when switched back into terminal.
-- This below line fixes that. Uncomment if needed.
-- vim.cmd('autocmd VimLeave,VimSuspend * set guicursor=a:ver90') -- Beam
-- vim.cmd('autocmd VimLeave,VimSuspend * set guicursor=a:hor20') -- Underline
-- NOTE: Above code doesn't take a value from the terminal's cursor and
-- replace it. It hardcodes the cursor shape.
-- And I think `ver` means vertical and `hor` means horizontal.
-- The numbers didn't make a difference in alacritty. Please change
-- the number to something that suits your needs if it looks weird.
2021-06-28 18:56:05 +02:00