summaryrefslogtreecommitdiff
path: root/lua/config.lua
diff options
context:
space:
mode:
authorHampusM <hampus@hampusmat.com>2022-09-18 11:39:25 +0200
committerHampusM <hampus@hampusmat.com>2022-09-18 11:39:25 +0200
commit3c238894c5b6f15c5f27cea8bd3785eb0f1ebf0f (patch)
tree68292df2b0cd698484d26057a4faf914e9ea6300 /lua/config.lua
parentd8fa264ac732286dcf9234bc40e60eeb7e230ca7 (diff)
add config
Diffstat (limited to 'lua/config.lua')
-rw-r--r--lua/config.lua69
1 files changed, 69 insertions, 0 deletions
diff --git a/lua/config.lua b/lua/config.lua
new file mode 100644
index 0000000..3a6e9b4
--- /dev/null
+++ b/lua/config.lua
@@ -0,0 +1,69 @@
+-- Indentation
+vim.o.tabstop = 4
+vim.o.softtabstop = 4
+vim.o.shiftwidth = 4
+vim.o.expandtab = false
+vim.o.autoindent = true
+vim.o.smartindent = true
+
+-- Line numbers
+vim.o.number = true
+vim.o.relativenumber = true
+
+-- Misc
+vim.o.conceallevel = 2
+vim.o.splitbelow = true
+vim.o.shortmess = vim.o.shortmess .. "c"
+vim.o.showmode = false
+vim.o.formatoptions = string.gsub(vim.o.formatoptions, "[cro]", "")
+vim.o.cmdheight = 2
+vim.o.errorbells = false
+vim.o.scrolloff = 8
+vim.o.encoding = "UTF-8"
+vim.o.fillchars = vim.o.fillchars .. "vert:█"
+vim.o.colorcolumn = "90"
+vim.o.signcolumn = "yes"
+
+-- Completion
+vim.o.complete = vim.o.complete .. ",kspell"
+-- vim.o.completeopt = "menuone,longest"
+vim.o.wildmenu = true
+vim.o.wildmode = "full"
+
+-- Searching
+vim.o.hlsearch = false
+vim.o.incsearch = true
+
+-- Backup
+vim.o.backup = false
+vim.o.writebackup = false
+
+-- Spell checking
+vim.o.spell = false
+
+-- Time
+vim.o.updatetime = 100
+vim.o.timeoutlen = 500
+vim.o.ttimeoutlen = 10
+
+-- Style
+vim.o.background = "dark"
+vim.o.termguicolors = true
+
+vim.g.mapleader = ","
+
+-- Plugins
+vim.g["vim_markdown_folding_disabled"] = 1
+
+vim.g.rustfmt_autosave = 1
+
+vim.g.nerdtree_tabs_open_on_console_startup = 1
+
+vim.g.indent_blankline_char = '¦'
+
+-- Custom globals
+vim.g.is_term_open = 0
+vim.g.terminal_height = 12
+vim.g.term_buf = 0
+vim.g.term_win = 0
+