From 11b04ad1e5ef81d42c4384af94d7ba4161f0c160 Mon Sep 17 00:00:00 2001 From: Jean-Pierre Appel Date: Tue, 21 Feb 2023 01:04:26 -0500 Subject: Added nvim and tmux config --- nvim/lua/colorscheme.lua | 1 + nvim/lua/keymap.lua | 22 +++++++++++++ nvim/lua/plugins.lua | 85 ++++++++++++++++++++++++++++++++++++++++++++++++ nvim/lua/telescope.lua | 2 ++ 4 files changed, 110 insertions(+) create mode 100644 nvim/lua/colorscheme.lua create mode 100644 nvim/lua/keymap.lua create mode 100644 nvim/lua/plugins.lua create mode 100644 nvim/lua/telescope.lua (limited to 'nvim/lua') diff --git a/nvim/lua/colorscheme.lua b/nvim/lua/colorscheme.lua new file mode 100644 index 0000000..1d79a5f --- /dev/null +++ b/nvim/lua/colorscheme.lua @@ -0,0 +1 @@ +vim.cmd("colorscheme catppuccin-mocha") diff --git a/nvim/lua/keymap.lua b/nvim/lua/keymap.lua new file mode 100644 index 0000000..883321b --- /dev/null +++ b/nvim/lua/keymap.lua @@ -0,0 +1,22 @@ +-- Provides convienent lua methods for binding keys +-- Source: Primeagen +local M = {} + +local function bind(op, outer_opts) + outer_opts = outer_opts or {noremap = true} + return function(lhs, rhs, opts) + opts = vim.tbl_extend("force", + outer_opts, + opts or {} + ) + vim.keymap.set(op, lhs, rhs, opts) + end +end + +M.nmap = bind("n", {noremap = false}) +M.nnoremap = bind("n") +M.vnoremap = bind("v") +M.xnoremap = bind("x") +M.inoremap = bind("i") + +return M diff --git a/nvim/lua/plugins.lua b/nvim/lua/plugins.lua new file mode 100644 index 0000000..47024bd --- /dev/null +++ b/nvim/lua/plugins.lua @@ -0,0 +1,85 @@ +return require('packer').startup(function(use) + use 'wbthomason/packer.nvim' -- package manager + use 'neovim/nvim-lspconfig' -- config for lsp + + -- common dependacy + use "nvim-lua/plenary.nvim" + + -- git + use 'tpope/vim-fugitive' -- close to native git command integrations + + + use { + 'nvim-telescope/telescope.nvim', tag = '0.1.0', -- fuzzy finder + requires = { {'nvim-lua/plenary.nvim'}, {'nvim-tree/nvim-web-devicons'} } + } + + -- completion + -- TODO:config completion and setup binds + use 'hrsh7th/nvim-cmp' + use { + 'hrsh7th/cmp-nvim-lsp', + requires = { {'hrsh7th/nvim-cmp'}, {'neovim/nvim-lspconfig'} } + } + use { + 'hrsh7th/cmp-path', + requires = { 'hrsh7th/nvim-cmp' } + } + use { + 'kdheepak/cmp-latex-symbols', + requires = { 'hrsh7th/nvim-cmp' } + } + + + -- pandoc + use 'vim-pandoc/vim-pandoc' + use 'vim-pandoc/vim-pandoc-syntax' + + -- tree sitter + use { + 'nvim-treesitter/nvim-treesitter', + run = ':TSUpdate' + } + + use { + 'numToStr/Comment.nvim', -- faster commentting + config = function() + require('Comment').setup() + end + } + + use 'habamax/vim-godot' + + -- TODO: configure tree-sitter to color current indentation level + use { + 'lukas-reineke/indent-blankline.nvim', -- show indentation levels + config = function() + require('indent_blankline').setup { + show_current_context = true, + show_current_context_start = true + } + end + } + + -- statusline/bufferline + use { + 'nvim-lualine/lualine.nvim', -- lualine + requires = { 'nvim-tree/nvim-web-devicons', opt = true }, + config = function() + require('lualine').setup() + end + } + use { + 'akinsho/bufferline.nvim', -- bufferline + tag = "v3.*", + requires = 'nvim-tree/nvim-web-devicons', + config = function() + require('bufferline').setup() + end + } + + -- cosmetic + use { "catppuccin/nvim", as = "catppuccin" } -- colorscheme + -- use 'kyazdani42/nvim-web-devicons' + +end) diff --git a/nvim/lua/telescope.lua b/nvim/lua/telescope.lua new file mode 100644 index 0000000..37d03a3 --- /dev/null +++ b/nvim/lua/telescope.lua @@ -0,0 +1,2 @@ +-- require("telescope").setup({ +-- }) -- cgit v1.2.3