Compare commits

...

2 Commits

Author SHA1 Message Date
pegasust e40bc60628 remove shade, inlay hints not showing 2022-11-23 17:02:56 +00:00
pegasust 0d5c2923f0 nvim: a bit better onboarding experience 2022-11-22 16:28:03 +00:00
1 changed files with 17 additions and 10 deletions

View File

@ -13,17 +13,17 @@
local data_dir = vim.fn.stdpath('data')
vim.cmd([[
let data_dir = has('nvim') ? stdpath('data') . '/site' : '~/.vim'
if empty(glob(data_dir . '/autoload/plug.vim'))
silent execute '!curl -fLo '.data_dir.'/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
let plug_path = data_dir . '/autoload/plug.vim'
if empty(glob(plug_path))
execute '!curl -fLo '.plug_path.' --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
execute 'so '.plug_path
endif
autocmd VimEnter * PlugInstall --sync | source $MYVIMRC
]])
--
-- vim-plug
local Plug = vim.fn['plug#']
-- TODO: Change this to relative datadir
vim.call('plug#begin', '~/.config/nvim/plugged')
vim.call('plug#begin')
-- libs and dependencies
Plug('nvim-lua/plenary.nvim')
@ -76,7 +76,6 @@ Plug('lukas-reineke/indent-blankline.nvim') -- identation lines on blank lines
Plug('kyazdani42/nvim-web-devicons') -- icons for folder and filetypes
Plug('m-demare/hlargs.nvim') -- highlights arguments; great for func prog
Plug('folke/todo-comments.nvim') -- Highlights TODO
Plug('TaDaa/vimade') -- shade alternative
-- other utilities
Plug('nvim-treesitter/nvim-treesitter', { run = ':TSUpdate' })
@ -87,7 +86,11 @@ Plug('mickael-menu/zk-nvim') -- Zettelkasten
---------
vim.call('plug#end')
vim.cmd([[
if len(filter(values(g:plugs), '!isdirectory(v:val.dir)'))
\| PlugInstall --sync | autocmd VimEnter * so $MYVIMRC
\| endif
]])
vim.cmd([[
set number relativenumber
@ -101,7 +104,6 @@ set scrolloff=30
set signcolumn=yes
set colorcolumn=80
set background=light
]])
vim.opt.lazyredraw = true
vim.opt.termguicolors = true
@ -374,6 +376,12 @@ remap('n', '<leader>gs', function() require('neogit').open({}) end);
-- LSP settings
-- This function gets run when an LSP connects to a particular buffer.
require("inlay-hints").setup {
only_current_line = true,
eol = {
right_align = true,
}
}
local on_attach = function(client, bufnr)
-- NOTE: Remember that lua is a real programming language, and as such it is possible
-- to define small helper and utility functions so you don't have to repeat yourself
@ -889,4 +897,3 @@ vim.cmd([[
let g:conjure#mapping#doc_word = v:false
]])