From 231e91d2fa56ff712a83902551c68a4748609a8f Mon Sep 17 00:00:00 2001 From: Steffen Rademacker Date: Tue, 29 Aug 2023 20:32:13 +0200 Subject: [PATCH] vim config and gruvbox-baby --- nvim/lua/config/flit.lua | 6 +++ nvim/lua/config/fzf.lua | 19 ---------- nvim/lua/config/leap.lua | 1 + nvim/lua/config/telescope.lua | 5 +++ nvim/lua/config/vsnip.lua | 2 +- nvim/lua/options.lua | 5 ++- nvim/lua/plugins.lua | 69 +++++++++++++---------------------- tmux.conf | 2 + zsh/zshrc | 4 ++ 9 files changed, 47 insertions(+), 66 deletions(-) create mode 100644 nvim/lua/config/flit.lua delete mode 100644 nvim/lua/config/fzf.lua create mode 100644 nvim/lua/config/leap.lua diff --git a/nvim/lua/config/flit.lua b/nvim/lua/config/flit.lua new file mode 100644 index 00000000..98f2fccd --- /dev/null +++ b/nvim/lua/config/flit.lua @@ -0,0 +1,6 @@ +require('flit').setup({ + keys = { f = 'f', F = 'F', t = 't', T = 'T' }, + labeled_modes = "v", + multiline = true, + opts = {} +}) diff --git a/nvim/lua/config/fzf.lua b/nvim/lua/config/fzf.lua deleted file mode 100644 index 0d6245c1..00000000 --- a/nvim/lua/config/fzf.lua +++ /dev/null @@ -1,19 +0,0 @@ -require('fzf-lua').setup({ - files = { - multiprocess = true, - }, - grep = { - multiprocess = true, - }, - git = { - files = { - multiprocess = true, - }, - }, - winopts = { - width = 0.98, - height = 0.89, - row = 0.55, - col = 0.48, - }, -}) diff --git a/nvim/lua/config/leap.lua b/nvim/lua/config/leap.lua new file mode 100644 index 00000000..3e597bf6 --- /dev/null +++ b/nvim/lua/config/leap.lua @@ -0,0 +1 @@ +require('leap').set_default_keymaps() diff --git a/nvim/lua/config/telescope.lua b/nvim/lua/config/telescope.lua index 904e8173..89d83b47 100644 --- a/nvim/lua/config/telescope.lua +++ b/nvim/lua/config/telescope.lua @@ -7,6 +7,11 @@ require('telescope').setup({ width = 0.9, height = 0.9, }, + borderchars = { + prompt = { "─", " ", " ", " ", "─", "─", " ", " " }, + results = { " " }, + preview = { " " }, + }, }, extensions = { fzf = { diff --git a/nvim/lua/config/vsnip.lua b/nvim/lua/config/vsnip.lua index 0093969a..b246cd5b 100644 --- a/nvim/lua/config/vsnip.lua +++ b/nvim/lua/config/vsnip.lua @@ -2,7 +2,7 @@ local g = vim.g -- vsnip config g.vsnip_snippet_dirs = { - os.getenv('HOME') .. '/Dotfiles/nvim/plugged/friendly-snippets/snippets', + os.getenv('HOME') .. '/.local/share/nvim/lazy/friendly-snippets/snippets/', os.getenv('HOME') .. '/Dotfiles/snippets/', } g.vsnip_filetypes = { diff --git a/nvim/lua/options.lua b/nvim/lua/options.lua index c46404f6..9c3edbd6 100644 --- a/nvim/lua/options.lua +++ b/nvim/lua/options.lua @@ -49,7 +49,8 @@ set.wildmode = { 'list:longest', 'list:full' } -- colorscheme and default language set.background = 'dark' set.termguicolors = true -g.gruvbox_italic = 1 -cmd 'colorscheme gruvbox' +-- g.gruvbox_baby_background_color = 'dark' +g.gruvbox_baby_telescope_theme = 1 +cmd 'colorscheme gruvbox-baby' cmd 'language en_US.UTF-8' diff --git a/nvim/lua/plugins.lua b/nvim/lua/plugins.lua index 38836e5d..1ceb5642 100644 --- a/nvim/lua/plugins.lua +++ b/nvim/lua/plugins.lua @@ -24,14 +24,13 @@ vim.g.maplocalleader = ' ' require('lazy').setup({ -- The colorscheme of choice - { 'ellisonleao/gruvbox.nvim', priority = 1000 }, + { 'luisiacc/gruvbox-baby', priority = 1000 }, - -- modern neovim with treesitter, lsp, null-ls, cmp and vsnip - -- remember to install all those tools since we do not use mason - -- see ../../install/3_vimux.sh - { 'hrsh7th/vim-vsnip', init = get_config('vsnip') }, - { 'jose-elias-alvarez/null-ls.nvim', init = get_config('null-ls'), dependencies = { 'nvim-lua/plenary.nvim' } }, - { 'neovim/nvim-lspconfig', init = get_config('lspconfig') }, + -- core pieces: telescope & fzf/terminal/tmux integration, + -- completion-engine + snippets + { 'voldikss/vim-floaterm', init = get_config('floaterm') }, + { 'wincent/terminus' }, + { 'christoomey/vim-tmux-navigator'}, { 'nvim-telescope/telescope.nvim', tag = '0.1.1', @@ -39,8 +38,7 @@ require('lazy').setup({ dependencies = { 'nvim-lua/plenary.nvim' } }, { 'nvim-telescope/telescope-fzf-native.nvim', build = 'make' }, - { 'nvim-treesitter/nvim-treesitter', init = get_config('treesitter'), build = ':TSUpdate' }, - { 'rafamadriz/friendly-snippets', dependencies = { 'hrsh7th/vim-vsnip' } }, + { 'hrsh7th/vim-vsnip', init = get_config('vsnip') }, { 'hrsh7th/nvim-cmp', init = get_config('cmp'), @@ -54,53 +52,34 @@ require('lazy').setup({ 'hrsh7th/cmp-vsnip', }, }, + { 'rafamadriz/friendly-snippets', dependencies = { 'hrsh7th/vim-vsnip' } }, + + -- more modern neovim with treesitter, lsp, auto-setup and + -- null-ls integration; see ../../install/3_vimux.sh + -- and null-ls-config for installed and supported tools (Eslint, TSC etc.) + { 'nvim-treesitter/nvim-treesitter', init = get_config('treesitter'), build = ':TSUpdate' }, + { 'neovim/nvim-lspconfig', init = get_config('lspconfig') }, + { 'jose-elias-alvarez/null-ls.nvim', init = get_config('null-ls'), dependencies = { 'nvim-lua/plenary.nvim' } }, + { 'editorconfig/editorconfig-vim' }, -- editing enhancements { 'AndrewRadev/splitjoin.vim' }, - { 'echasnovski/mini.ai', version = '*' }, { 'numToStr/Comment.nvim', config = true }, { 'tpope/vim-ragtag' }, { 'tpope/vim-repeat' }, { 'tpope/vim-surround' }, { 'windwp/nvim-autopairs', config = true }, - -- git and other external tools integration - { 'christoomey/vim-tmux-navigator'}, - { 'editorconfig/editorconfig-vim' }, + -- interface/code-navigation enhancements, git and others + { 'ggandor/leap.nvim', init = get_config('leap') }, + { 'ggandor/flit.nvim', init = get_config('flit') }, { 'lewis6991/gitsigns.nvim', config = true }, - { 'voldikss/vim-floaterm', init = get_config('floaterm') }, - { 'wincent/terminus' }, - - -- ui enhancements / navigation - { -- nice popup messages - 'rcarriga/nvim-notify', - init = function() vim.notify = require('notify') end - }, - { -- a nice status line - 'nvim-lualine/lualine.nvim', + { 'rcarriga/nvim-notify', init = function() vim.notify = require('notify') end }, + { 'nvim-lualine/lualine.nvim', dependencies = { 'kyazdani42/nvim-web-devicons' }, - event = 'VimEnter', opts = { options = { theme = 'gruvbox' } }, }, - { -- easy jump navigation - 'ggandor/leap.nvim', - event = 'BufReadPre', - init = function() require('leap').set_default_keymaps() end, - }, - { -- better f t - 'ggandor/flit.nvim', - event = 'BufReadPre', - init = function() - require('flit').setup { - keys = { f = 'f', F = 'F', t = 't', T = 'T' }, - labeled_modes = "v", - multiline = true, - opts = {} - } - end, - }, - { -- colorizer for nice css-colors - 'norcalli/nvim-colorizer.lua', + { 'norcalli/nvim-colorizer.lua', event = 'BufReadPre', opts = { css = { css = true }, @@ -110,7 +89,9 @@ require('lazy').setup({ javascript = { css = true }, }, }, - { -- and neorg for todo-lists etc. + + -- and neorg for todo-lists etc. + { 'nvim-neorg/neorg', build = ':Neorg sync-parsers', opts = { diff --git a/tmux.conf b/tmux.conf index dc1af062..2a637748 100644 --- a/tmux.conf +++ b/tmux.conf @@ -25,6 +25,8 @@ bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= bind -n WheelDownPane select-pane -t= \; send-keys -M bind -n C-WheelUpPane select-pane -t= \; copy-mode -e \; send-keys -M +source-file /Users/webgefrickel/.local/share/nvim/lazy/gruvbox-baby/extras/tmux/MEDIUM.tmux + # Custom statusbar, gruvbox style set -g status-style bg=black,fg=yellow,default set -g pane-border-style 'fg=#504945' diff --git a/zsh/zshrc b/zsh/zshrc index a249e567..287c3fbd 100644 --- a/zsh/zshrc +++ b/zsh/zshrc @@ -33,3 +33,7 @@ eval "$(starship init zsh)" eval "$(jump shell)" eval "$(rbenv init - --no-rehash)" eval "$(pyenv init --path --no-rehash)" + +# colors +source ~/.local/share/nvim/lazy/gruvbox-baby/extras/bash/MEDIUM.bash +source ~/.local/share/nvim/lazy/gruvbox-baby/extras/fzf/fzf.theme