summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohannes Stoelp <johannes.stoelp@gmail.com>2023-04-30 16:56:53 +0200
committerJohannes Stoelp <johannes.stoelp@gmail.com>2023-04-30 16:56:53 +0200
commit56c01629c682063c87b762bb177a2980ff3ae7a4 (patch)
tree98211887a7d5b31356a008983e9f12351a10e517
parentcab67a48d640bdef7225e54cf1f144b8693586c9 (diff)
downloaddotfiles-56c01629c682063c87b762bb177a2980ff3ae7a4.tar.gz
dotfiles-56c01629c682063c87b762bb177a2980ff3ae7a4.zip
nvim add TS and use default color; git update color
-rw-r--r--gitconfig2
-rw-r--r--nvim.init.vim22
2 files changed, 17 insertions, 7 deletions
diff --git a/gitconfig b/gitconfig
index 948036a..b299cce 100644
--- a/gitconfig
+++ b/gitconfig
@@ -25,6 +25,6 @@
# %s commit message subject
# %>(N) set width, padd space on the left
# %<(N) set width, padd space on the right
- pretty = format:%C(auto)%h %C(blue)%>(10)%ad %C(green)%>(8)%aN %C(auto)%d %Creset%s
+ pretty = format:%C(auto)%h %C(cyan)%>(10)%ad %C(green)%>(8)%aN %C(auto)%d %Creset%s
[alias]
graph = log --graph --decorate --pretty=oneline --abbrev-commit --all
diff --git a/nvim.init.vim b/nvim.init.vim
index aec04d2..c551b7e 100644
--- a/nvim.init.vim
+++ b/nvim.init.vim
@@ -32,15 +32,22 @@ call plug#begin('~/.nvim/plugged')
Plug 'nvim-lua/plenary.nvim'
Plug 'nvim-telescope/telescope.nvim'
Plug 'nvim-telescope/telescope-fzf-native.nvim', { 'do': 'make' }
+
+ " Treesitter
+ Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'}
+ Plug 'nvim-treesitter/nvim-treesitter-context'
call plug#end()
" -----------------
" Setters.
" -----------------
-set termguicolors
+"set termguicolors
set background=dark
-colorscheme base16-default-dark
+"colorscheme base16-default-dark
+"colorscheme base16-onedark
+highlight Pmenu ctermbg=DarkGray guibg=DarkGrey
+highlight PmenuSel ctermfg=Black guifg=Black ctermbg=LightGray guibg=LightGray
set relativenumber
set number
@@ -90,8 +97,8 @@ cmp.setup({
end,
},
mapping = cmp.mapping.preset.insert({
- ['<C-b>'] = cmp.mapping.scroll_docs(-4),
- ['<C-f>'] = cmp.mapping.scroll_docs(4),
+ ['<C-u>'] = cmp.mapping.scroll_docs(-4),
+ ['<C-d>'] = cmp.mapping.scroll_docs(4),
['<C-Space>'] = cmp.mapping.complete(),
['<C-e>'] = cmp.mapping.abort(),
['<CR>'] = cmp.mapping.confirm({ select = false }),
@@ -107,14 +114,17 @@ cmp.setup({
})
-- Setup lspconfig.
-local capabilities = require('cmp_nvim_lsp').update_capabilities(vim.lsp.protocol.make_client_capabilities())
+local capabilities = require('cmp_nvim_lsp').default_capabilities(vim.lsp.protocol.make_client_capabilities())
+
-- Disable LSP snippet completion.
capabilities.textDocument.completion.completionItem.snippetSupport = false
--print(vim.inspect(capabilities))
-local on_attach = function(_client, bufnr)
+local on_attach = function(client, bufnr)
-- Install `omnifunc` completion handler, get completion with <C-x><C-o>.
vim.api.nvim_buf_set_option(bufnr, "omnifunc", "v:lua.vim.lsp.omnifunc")
+ -- Disable LSP highlighting.
+ client.server_capabilities.semanticTokensProvider = nil
end
-- Setup rust-analyzer.