From 7e82242013d5231763d7abcb2b163f13b62ee0c1 Mon Sep 17 00:00:00 2001 From: tiyn Date: Sat, 29 Jul 2023 17:19:25 +0200 Subject: [PATCH] nvim: swapped gitgutter for gitsigns and lightline for lualine --- .config/nvim/lua/loadplugins.lua | 13 ++++++---- .config/nvim/plugin/gitsigns.lua | 2 ++ .config/nvim/plugin/lightline.lua | 2 -- .config/nvim/plugin/lualine.lua | 41 +++++++++++++++++++++++++++++++ 4 files changed, 51 insertions(+), 7 deletions(-) create mode 100644 .config/nvim/plugin/gitsigns.lua delete mode 100644 .config/nvim/plugin/lightline.lua create mode 100644 .config/nvim/plugin/lualine.lua diff --git a/.config/nvim/lua/loadplugins.lua b/.config/nvim/lua/loadplugins.lua index 1dc1366..33f06bc 100644 --- a/.config/nvim/lua/loadplugins.lua +++ b/.config/nvim/lua/loadplugins.lua @@ -19,13 +19,19 @@ return require("packer").startup(function(use) -- package manager (first entry) use { 'wbthomason/packer.nvim' } + -- indicate git diff status of line + use { 'lewis6991/gitsigns.nvim' } + -- improved java syntax highlighting use { 'uiiaoo/java-syntax.vim', ft = { 'java' } } -- custom statusline - use { 'itchyny/lightline.vim', - require = { "tiyn/vim-tccs" } } + use { + 'nvim-lualine/lualine.nvim', + requires = { 'nvim-tree/nvim-web-devicons', + opt = true } + } -- show signature while typing use { 'ray-x/lsp_signature.nvim' } @@ -105,9 +111,6 @@ return require("packer").startup(function(use) -- git wrapper use { 'tpope/vim-fugitive' } - -- indicate git diff status of line - use { 'airblade/vim-gitgutter' } - -- golang language support use { 'fatih/vim-go', ft = { 'go' } } diff --git a/.config/nvim/plugin/gitsigns.lua b/.config/nvim/plugin/gitsigns.lua new file mode 100644 index 0000000..fa23a5e --- /dev/null +++ b/.config/nvim/plugin/gitsigns.lua @@ -0,0 +1,2 @@ +-- lewis6991/gitsigns.nvim +require('gitsigns').setup() diff --git a/.config/nvim/plugin/lightline.lua b/.config/nvim/plugin/lightline.lua deleted file mode 100644 index 09becbf..0000000 --- a/.config/nvim/plugin/lightline.lua +++ /dev/null @@ -1,2 +0,0 @@ --- itchyny/lightline.vim -vim.g.lightline = { colorscheme = 'tccs' } diff --git a/.config/nvim/plugin/lualine.lua b/.config/nvim/plugin/lualine.lua new file mode 100644 index 0000000..e7053f1 --- /dev/null +++ b/.config/nvim/plugin/lualine.lua @@ -0,0 +1,41 @@ +-- nvim-lualine/lualine.nvim +require('lualine').setup { + options = { + icons_enabled = true, + theme = 'tccs', + component_separators = { left = '', right = '' }, + section_separators = { left = '', right = '' }, + disabled_filetypes = { + statusline = {}, + winbar = {}, + }, + ignore_focus = {}, + always_divide_middle = true, + globalstatus = false, + refresh = { + statusline = 1000, + tabline = 1000, + winbar = 1000, + } + }, + sections = { + lualine_a = { 'mode' }, + lualine_b = { 'branch', 'diff', 'diagnostics' }, + lualine_c = { 'filename' }, + lualine_x = { 'encoding', 'fileformat', 'filetype' }, + lualine_y = { 'progress' }, + lualine_z = { 'location' } + }, + inactive_sections = { + lualine_a = {}, + lualine_b = {}, + lualine_c = { 'filename' }, + lualine_x = { 'location' }, + lualine_y = {}, + lualine_z = {} + }, + tabline = {}, + winbar = {}, + inactive_winbar = {}, + extensions = {} +}