summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Luevano Alvarado <david@luevano.xyz>2023-06-03 09:24:23 -0600
committerDavid Luevano Alvarado <david@luevano.xyz>2023-06-03 09:24:23 -0600
commitfbdfc3dfe274ba0365bf02a972878bbcf0b2bf5c (patch)
treee8bd25f8cb7df4e966f2d4552e9a7998262e6ce5
parentd2915932808b807d83a1dcb42870d5bdf66f03fd (diff)
initial plugins move to plugins dir
-rw-r--r--init.lua126
-rw-r--r--lua/custom/plugins/init.lua5
-rw-r--r--lua/plugins/init.lua125
3 files changed, 127 insertions, 129 deletions
diff --git a/init.lua b/init.lua
index 507b891..160aef6 100644
--- a/init.lua
+++ b/init.lua
@@ -1,4 +1,3 @@
--- Set <space> as the leader key
-- NOTE: Must happen before plugins are required (otherwise wrong leader will be used)
vim.g.mapleader = ' '
vim.g.maplocalleader = ' '
@@ -12,134 +11,13 @@ if not vim.loop.fs_stat(lazypath) then
'clone',
'--filter=blob:none',
'https://github.com/folke/lazy.nvim.git',
- '--branch=stable', -- latest stable release
+ '--branch=stable',
lazypath,
}
end
vim.opt.rtp:prepend(lazypath)
-require('lazy').setup({
- -- Git related plugins
- 'tpope/vim-fugitive',
- 'tpope/vim-rhubarb',
-
- -- Detect tabstop and shiftwidth automatically
- -- luevano: not sure how I feel about this, need to check later
- 'tpope/vim-sleuth',
-
- {
- -- LSP Configuration & Plugins
- 'neovim/nvim-lspconfig',
- dependencies = {
- -- Automatically install LSPs to stdpath for neovim
- { 'williamboman/mason.nvim', config = true },
- 'williamboman/mason-lspconfig.nvim',
-
- -- Useful status updates for LSP
- -- NOTE: `opts = {}` is the same as calling `require('fidget').setup({})`
- { 'j-hui/fidget.nvim', opts = {} },
-
- -- Additional lua configuration, makes nvim stuff amazing!
- 'folke/neodev.nvim',
- },
- },
-
- {
- -- Autocompletion
- 'hrsh7th/nvim-cmp',
- dependencies = {
- -- Snippet Engine & its associated nvim-cmp source
- 'L3MON4D3/LuaSnip',
- 'saadparwaiz1/cmp_luasnip',
-
- -- Adds LSP completion capabilities
- 'hrsh7th/cmp-nvim-lsp',
-
- -- Adds a number of user-friendly snippets
- 'rafamadriz/friendly-snippets',
- },
- },
-
- -- Useful plugin to show you pending keybinds.
- { 'folke/which-key.nvim', opts = {} },
- {
- -- Adds git releated signs to the gutter, as well as utilities for managing changes
- 'lewis6991/gitsigns.nvim',
- opts = {
- signs = {
- add = { text = '+' },
- change = { text = '~' },
- delete = { text = '_' },
- topdelete = { text = '‾' },
- changedelete = { text = '~' },
- },
- on_attach = function(bufnr)
- vim.keymap.set('n', '<leader>gp', require('gitsigns').prev_hunk, { buffer = bufnr, desc = '[G]o to [P]revious Hunk' })
- vim.keymap.set('n', '<leader>gn', require('gitsigns').next_hunk, { buffer = bufnr, desc = '[G]o to [N]ext Hunk' })
- vim.keymap.set('n', '<leader>ph', require('gitsigns').preview_hunk, { buffer = bufnr, desc = '[P]review [H]unk' })
- end,
- },
- },
-
- {
- -- Theme inspired by Atom
- 'navarasu/onedark.nvim',
- priority = 1000,
- config = function()
- vim.cmd.colorscheme 'onedark'
- end,
- },
-
- {
- -- Set lualine as statusline
- 'nvim-lualine/lualine.nvim',
- opts = {
- options = {
- icons_enabled = false,
- theme = 'onedark',
- component_separators = '|',
- section_separators = '',
- },
- },
- },
-
- {
- -- Add indentation guides even on blank lines
- 'lukas-reineke/indent-blankline.nvim',
- -- Enable `lukas-reineke/indent-blankline.nvim`
- opts = {
- char = '┊',
- show_trailing_blankline_indent = false,
- },
- },
-
- -- "gc" to comment visual regions/lines
- { 'numToStr/Comment.nvim', opts = {} },
-
- -- Fuzzy Finder (files, lsp, etc)
- { 'nvim-telescope/telescope.nvim', branch = '0.1.x', dependencies = { 'nvim-lua/plenary.nvim' } },
-
- -- Fuzzy Finder Algorithm which requires local dependencies to be built
- {
- 'nvim-telescope/telescope-fzf-native.nvim',
- build = 'make',
- cond = function()
- return vim.fn.executable 'make' == 1
- end,
- },
-
- {
- -- Highlight, edit, and navigate code
- 'nvim-treesitter/nvim-treesitter',
- dependencies = {
- 'nvim-treesitter/nvim-treesitter-textobjects',
- },
- build = ':TSUpdate',
- },
-
- -- For additional information see: https://github.com/folke/lazy.nvim#-structuring-your-plugins
- { import = 'custom.plugins' },
-}, {})
+require('lazy').setup('plugins', {})
-- [[ Setting options ]]
-- See `:help vim.o`
diff --git a/lua/custom/plugins/init.lua b/lua/custom/plugins/init.lua
deleted file mode 100644
index be0eb9d..0000000
--- a/lua/custom/plugins/init.lua
+++ /dev/null
@@ -1,5 +0,0 @@
--- You can add your own plugins here or in other files in this directory!
--- I promise not to create any merge conflicts in this directory :)
---
--- See the kickstart.nvim README for more information
-return {}
diff --git a/lua/plugins/init.lua b/lua/plugins/init.lua
new file mode 100644
index 0000000..f89ea0a
--- /dev/null
+++ b/lua/plugins/init.lua
@@ -0,0 +1,125 @@
+-- You can add your own plugins here or in other files in this directory!
+-- I promise not to create any merge conflicts in this directory :)
+--
+-- See the kickstart.nvim README for more information
+return {
+ -- Git related plugins
+ 'tpope/vim-fugitive',
+ 'tpope/vim-rhubarb',
+
+ -- Detect tabstop and shiftwidth automatically
+ -- luevano: not sure how I feel about this, need to check later
+ 'tpope/vim-sleuth',
+
+ {
+ -- LSP Configuration & Plugins
+ 'neovim/nvim-lspconfig',
+ dependencies = {
+ -- Automatically install LSPs to stdpath for neovim
+ { 'williamboman/mason.nvim', config = true },
+ 'williamboman/mason-lspconfig.nvim',
+
+ -- Useful status updates for LSP
+ -- NOTE: `opts = {}` is the same as calling `require('fidget').setup({})`
+ { 'j-hui/fidget.nvim', opts = {} },
+
+ -- Additional lua configuration, makes nvim stuff amazing!
+ 'folke/neodev.nvim',
+ },
+ },
+
+ {
+ -- Autocompletion
+ 'hrsh7th/nvim-cmp',
+ dependencies = {
+ -- Snippet Engine & its associated nvim-cmp source
+ 'L3MON4D3/LuaSnip',
+ 'saadparwaiz1/cmp_luasnip',
+
+ -- Adds LSP completion capabilities
+ 'hrsh7th/cmp-nvim-lsp',
+
+ -- Adds a number of user-friendly snippets
+ 'rafamadriz/friendly-snippets',
+ },
+ },
+
+ -- Useful plugin to show you pending keybinds.
+ { 'folke/which-key.nvim', opts = {} },
+ {
+ -- Adds git releated signs to the gutter, as well as utilities for managing changes
+ 'lewis6991/gitsigns.nvim',
+ opts = {
+ signs = {
+ add = { text = '+' },
+ change = { text = '~' },
+ delete = { text = '_' },
+ topdelete = { text = '‾' },
+ changedelete = { text = '~' },
+ },
+ on_attach = function(bufnr)
+ vim.keymap.set('n', '<leader>gp', require('gitsigns').prev_hunk, { buffer = bufnr, desc = '[G]o to [P]revious Hunk' })
+ vim.keymap.set('n', '<leader>gn', require('gitsigns').next_hunk, { buffer = bufnr, desc = '[G]o to [N]ext Hunk' })
+ vim.keymap.set('n', '<leader>ph', require('gitsigns').preview_hunk, { buffer = bufnr, desc = '[P]review [H]unk' })
+ end,
+ },
+ },
+
+ {
+ -- Theme inspired by Atom
+ 'navarasu/onedark.nvim',
+ priority = 1000,
+ config = function()
+ vim.cmd.colorscheme 'onedark'
+ end,
+ },
+
+ {
+ -- Set lualine as statusline
+ 'nvim-lualine/lualine.nvim',
+ opts = {
+ options = {
+ icons_enabled = false,
+ theme = 'onedark',
+ component_separators = '|',
+ section_separators = '',
+ },
+ },
+ },
+
+ {
+ -- Add indentation guides even on blank lines
+ 'lukas-reineke/indent-blankline.nvim',
+ -- Enable `lukas-reineke/indent-blankline.nvim`
+ opts = {
+ char = '┊',
+ show_trailing_blankline_indent = false,
+ },
+ },
+
+ -- "gc" to comment visual regions/lines
+ { 'numToStr/Comment.nvim', opts = {} },
+
+ -- Fuzzy Finder (files, lsp, etc)
+ { 'nvim-telescope/telescope.nvim', branch = '0.1.x', dependencies = { 'nvim-lua/plenary.nvim' } },
+
+ -- Fuzzy Finder Algorithm which requires local dependencies to be built
+ {
+ 'nvim-telescope/telescope-fzf-native.nvim',
+ build = 'make',
+ cond = function()
+ return vim.fn.executable 'make' == 1
+ end,
+ },
+
+ {
+ -- Highlight, edit, and navigate code
+ 'nvim-treesitter/nvim-treesitter',
+ dependencies = {
+ 'nvim-treesitter/nvim-treesitter-textobjects',
+ },
+ build = ':TSUpdate',
+ },
+}
+
+-- vim: ts=2 sts=2 sw=2 et