summaryrefslogtreecommitdiffstats
path: root/.config/nvim
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--.config/nvim/init.lua3
-rw-r--r--.config/nvim/lua/settings.lua46
-rw-r--r--.config/nvim/settings.vim44
3 files changed, 48 insertions, 45 deletions
diff --git a/.config/nvim/init.lua b/.config/nvim/init.lua
index 7cd3e97..d9c22e6 100644
--- a/.config/nvim/init.lua
+++ b/.config/nvim/init.lua
@@ -16,7 +16,8 @@ confdir = os.getenv('XDG_CONFIG_HOME')
vim.cmd('set runtimepath^=/home/r_bousset/.config/nvim runtimepath+=/home/jozan/.config/nvim/after')
vim.cmd('let &packpath = &runtimepath')
require('plug')
-vim.cmd('source ' .. confdir .. '/nvim/settings.vim')
+require('settings')
+-- vim.cmd('source ' .. confdir .. '/nvim/settings.vim')
vim.cmd('source ' .. confdir .. '/nvim/bindings.vim')
vim.cmd('source ' .. confdir .. '/nvim/sidebars.vim')
vim.cmd('source ' .. confdir .. '/nvim/langs.vim')
diff --git a/.config/nvim/lua/settings.lua b/.config/nvim/lua/settings.lua
new file mode 100644
index 0000000..ece5f6f
--- /dev/null
+++ b/.config/nvim/lua/settings.lua
@@ -0,0 +1,46 @@
+vim.opt.autochdir = false
+vim.opt.bg = 'dark'
+vim.opt.cindent = true
+vim.cmd [[
+set cinoptions=>s,e0,n0,f0,{0,}0,^0,L-1,:s,=s,l1,b0,gs,h0,N0,E0,p0,t0,i0,+s
+set cinoptions+=c1,C0,/0,(s,us,U0,w1,Ws,k0,m0,M1,)20,*70,#0
+set clipboard^=unnamedplus
+set path+=**
+set shortmess+=c
+]]
+vim.opt.completeopt = 'menuone,noinsert,noselect,preview'
+vim.opt.cursorline = true
+vim.opt.encoding = 'utf-8'
+vim.opt.go = 'a'
+vim.opt.hidden = true
+vim.opt.makeprg = 'make'
+vim.opt.mouse = 'a'
+vim.opt.compatible = false
+vim.opt.expandtab = false
+vim.opt.hlsearch = false
+vim.opt.number = true
+vim.opt.shiftwidth = 4
+vim.opt.softtabstop = 4
+vim.opt.ruler = true
+vim.opt.tabstop = 4
+vim.opt.textwidth = 80
+vim.opt.timeoutlen = 500
+vim.opt.undodir = '/tmp/nvim_undo'
+vim.opt.undofile = true
+vim.opt.wildmode = 'longest,list,full'
+vim.opt.directory = '/tmp/nvim_swap'
+vim.opt.wrap = true
+vim.opt.textwidth = 0
+vim.cmd [[
+syntax on
+filetype plugin indent on
+colorscheme gruvbox-material
+highlight Normal ctermbg=none guibg=none
+highlight NonText ctermbg=none guibg=none
+highlight LineNr ctermbg=none guibg=none
+highlight EndOfBuffer ctermbg=none guibg=none
+autocmd FileType * setlocal formatoptions-=c formatoptions-=r formatoptions-=o
+]]
+vim.g.mapleader = '\\'
+vim.g.maplocalleader = '\\'
+vim.g['battery#update_statusline'] = 1
diff --git a/.config/nvim/settings.vim b/.config/nvim/settings.vim
deleted file mode 100644
index fcfb55f..0000000
--- a/.config/nvim/settings.vim
+++ /dev/null
@@ -1,44 +0,0 @@
-set noautochdir
-set bg=dark
-set cindent
-set cinoptions=>s,e0,n0,f0,{0,}0,^0,L-1,:s,=s,l1,b0,gs,h0,N0,E0,p0,t0,i0,+s
-set cinoptions+=c1,C0,/0,(s,us,U0,w1,Ws,k0,m0,M1,)20,*70,#0
-set clipboard^=unnamedplus
-set completeopt=menuone,noinsert,noselect,preview
-set cursorline
-set encoding=utf-8
-set go=a
-set hidden
-set makeprg=gmake
-set mouse=a
-set nocompatible
-set noexpandtab
-set nohlsearch
-set number
-set path+=**
-set shiftwidth=4
-set shortmess+=c
-set softtabstop=4
-set ruler
-set tabstop=4
-set textwidth=80
-set timeoutlen=500
-set undodir=/tmp/nvim_undo
-set undofile
-set wildmode=longest,list,full
-set directory=/tmp/nvim_swap
-set wrap
-set textwidth=0
-syntax on
-filetype plugin indent on
-" autocmd ColorScheme * highlight Normal ctermbg=NONE guibg=NONE
-colorscheme gruvbox-material
-highlight Normal ctermbg=none guibg=none
-highlight NonText ctermbg=none guibg=none
-highlight LineNr ctermbg=none guibg=none
-highlight EndOfBuffer ctermbg=none guibg=none
-let mapleader="\\"
-let maplocalleader="\\"
-" Disables automatic commenting on newline:
-autocmd FileType * setlocal formatoptions-=c formatoptions-=r formatoptions-=o
-let g:battery#update_statusline = 1 " For statusline.