feat: add some plugins
This commit is contained in:
parent
a87fdc2396
commit
28404d2c5e
10
init.lua
10
init.lua
|
@ -25,11 +25,11 @@ alias nvi='NVIM_APPNAME="kickstart-tsorabel" nvim'
|
||||||
|
|
||||||
What is Kickstart?
|
What is Kickstart?
|
||||||
|
|
||||||
Kickstart.nvim is *not* a distribution.
|
Kickstart.nvim is *not* a distribution.
|
||||||
|
|
||||||
Kickstart.nvim is a starting point for your own configuration.
|
Kickstart.nvim is a starting point for your own configuration.
|
||||||
The goal is that you can read every line of code, top-to-bottom, understand
|
The gal is that you can read every line of code, top-to-bottom, understand
|
||||||
what your configuration is doing, and modify it to suit your needs.
|
what our configuration is doing, and modify it to suit your needs.
|
||||||
|
|
||||||
Once you've done that, you can start exploring, configuring and tinkering to
|
Once you've done that, you can start exploring, configuring and tinkering to
|
||||||
make Neovim your own! That might mean leaving Kickstart just the way it is for a while
|
make Neovim your own! That might mean leaving Kickstart just the way it is for a while
|
||||||
|
@ -686,7 +686,7 @@ require('lazy').setup({
|
||||||
markdown = { 'prettier' },
|
markdown = { 'prettier' },
|
||||||
graphql = { 'prettier' },
|
graphql = { 'prettier' },
|
||||||
lua = { 'stylua' },
|
lua = { 'stylua' },
|
||||||
rust = { 'rustfmt' },
|
rust = { 'prettier' },
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -943,5 +943,5 @@ map({ 'n' }, '<leader>wb', '<cmd>vs<CR>', { desc = 'New [W]orkspace [B]uffer' })
|
||||||
-- map({ 'n' }, '<C-m>', '<cmd>vertical res -5^M<CR>', { desc = 'Buffer - width' })
|
-- map({ 'n' }, '<C-m>', '<cmd>vertical res -5^M<CR>', { desc = 'Buffer - width' })
|
||||||
map({ 'n' }, '<C-m>', '<cmd>vertical res +5^M<CR>', { desc = 'Buffer + width' })
|
map({ 'n' }, '<C-m>', '<cmd>vertical res +5^M<CR>', { desc = 'Buffer + width' })
|
||||||
|
|
||||||
--CarbonNow Screenshot
|
--Screenshot with carbon now
|
||||||
map({ 'v' }, '<leader>s', ':CarbonNow<CR>', { desc = '[S]creenshoot with carbon now' })
|
map({ 'v' }, '<leader>s', ':CarbonNow<CR>', { desc = '[S]creenshoot with carbon now' })
|
||||||
|
|
|
@ -0,0 +1,27 @@
|
||||||
|
return {
|
||||||
|
'ellisonleao/carbon-now.nvim',
|
||||||
|
lazy = true,
|
||||||
|
cmd = 'CarbonNow',
|
||||||
|
-- @param opts cn.ConfigSchema
|
||||||
|
opts = {
|
||||||
|
base_url = 'https://carbon.now.sh/',
|
||||||
|
open_cmd = 'xdg-open',
|
||||||
|
options = {
|
||||||
|
bg = 'gray',
|
||||||
|
drop_shadow_blur = '68px',
|
||||||
|
drop_shadow = false,
|
||||||
|
drop_shadow_offset_y = '20px',
|
||||||
|
font_family = 'JetBrains Mono',
|
||||||
|
font_size = '16px',
|
||||||
|
line_height = '124%',
|
||||||
|
line_numbers = true,
|
||||||
|
theme = 'verminal',
|
||||||
|
titlebar = 'Made with carbon-now.nvim',
|
||||||
|
watermark = false,
|
||||||
|
width = '680',
|
||||||
|
window_theme = 'sharp',
|
||||||
|
padding_horizontal = '0px',
|
||||||
|
padding_vertical = '0px',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
|
@ -0,0 +1,84 @@
|
||||||
|
return {
|
||||||
|
'nvimdev/dashboard-nvim',
|
||||||
|
event = 'VimEnter',
|
||||||
|
config = function()
|
||||||
|
local harpoon = require 'harpoon'
|
||||||
|
require('dashboard').setup {
|
||||||
|
theme = 'doom', -- theme is doom and hyper default is hyper
|
||||||
|
disable_move = false,
|
||||||
|
config = {
|
||||||
|
week_header = {
|
||||||
|
enable = true,
|
||||||
|
},
|
||||||
|
center = {
|
||||||
|
{
|
||||||
|
icon = ' ',
|
||||||
|
icon_hl = 'group',
|
||||||
|
desc = 'Open Harpoon',
|
||||||
|
desc_hl = 'group',
|
||||||
|
key = 'h',
|
||||||
|
key_hl = 'group',
|
||||||
|
key_format = ' [%s]', -- `%s` will be substituted with value of `key`
|
||||||
|
action = function()
|
||||||
|
harpoon.ui:toggle_quick_menu(harpoon:list())
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
icon = ' ',
|
||||||
|
icon_hl = 'group',
|
||||||
|
desc = 'Telescope find files',
|
||||||
|
desc_hl = 'group',
|
||||||
|
key = 'f',
|
||||||
|
key_hl = 'group',
|
||||||
|
key_format = ' [%s]', -- `%s` will be substituted with value of `key`
|
||||||
|
action = ':Telescope find_files',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
icon = ' ',
|
||||||
|
icon_hl = 'group',
|
||||||
|
desc = 'Telescope find world',
|
||||||
|
desc_hl = 'group',
|
||||||
|
key = 'w',
|
||||||
|
key_hl = 'group',
|
||||||
|
key_format = ' [%s]', -- `%s` will be substituted with value of `key`
|
||||||
|
action = ':Telescope live_grep',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
icon = ' ',
|
||||||
|
icon_hl = 'group',
|
||||||
|
desc = 'Telescope commits',
|
||||||
|
desc_hl = 'group',
|
||||||
|
key = 'c',
|
||||||
|
key_hl = 'group',
|
||||||
|
key_format = ' [%s]', -- `%s` will be substituted with value of `key`
|
||||||
|
action = ':Telescope git_commits',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
shortcut = {
|
||||||
|
{ desc = ' Update', group = '@property', action = 'Lazy update', key = 'u' },
|
||||||
|
{
|
||||||
|
icon = ' ',
|
||||||
|
icon_hl = '@variable',
|
||||||
|
desc = 'Files',
|
||||||
|
group = 'Label',
|
||||||
|
action = 'Telescope find_files',
|
||||||
|
key = 'f',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
desc = ' Apps',
|
||||||
|
group = 'DiagnosticHint',
|
||||||
|
action = 'Telescope app',
|
||||||
|
key = 'a',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
desc = ' dotfiles',
|
||||||
|
group = 'Number',
|
||||||
|
action = 'Telescope dotfiles',
|
||||||
|
key = 'd',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
end,
|
||||||
|
dependencies = { { 'nvim-tree/nvim-web-devicons' } },
|
||||||
|
}
|
|
@ -0,0 +1,59 @@
|
||||||
|
return {
|
||||||
|
'ThePrimeagen/harpoon',
|
||||||
|
branch = 'harpoon2',
|
||||||
|
|
||||||
|
dependencies = { 'nvim-lua/plenary.nvim' },
|
||||||
|
config = function()
|
||||||
|
local harpoon = require 'harpoon'
|
||||||
|
harpoon:setup {}
|
||||||
|
vim.keymap.set({ 'n' }, '<leader>a', function()
|
||||||
|
harpoon:list():append()
|
||||||
|
end, { desc = '[A]ppend File to harpoon' })
|
||||||
|
vim.keymap.set('n', '<C-h>', function()
|
||||||
|
harpoon.ui:toggle_quick_menu(harpoon:list())
|
||||||
|
end, { desc = '[H]arpoon quick menu' })
|
||||||
|
|
||||||
|
vim.keymap.set('n', '<C-t>', function()
|
||||||
|
harpoon:list():select(1)
|
||||||
|
end)
|
||||||
|
vim.keymap.set('n', '<C-g>', function()
|
||||||
|
harpoon:list():select(2)
|
||||||
|
end)
|
||||||
|
vim.keymap.set('n', '<C-b>', function()
|
||||||
|
harpoon:list():select(3)
|
||||||
|
end)
|
||||||
|
vim.keymap.set('n', '<C-s>', function()
|
||||||
|
harpoon:list():select(4)
|
||||||
|
end)
|
||||||
|
|
||||||
|
-- Toggle previous & next buffers stored within Harpoon list
|
||||||
|
-- vim.keymap.set('n', '<C-p>', function()
|
||||||
|
-- harpoon:list():next()
|
||||||
|
-- end)
|
||||||
|
-- vim.keymap.set('n', '<C-n>', function()
|
||||||
|
-- harpoon:list():prev()
|
||||||
|
-- end)
|
||||||
|
local conf = require('telescope.config').values
|
||||||
|
local function toggle_telescope(harpoon_files)
|
||||||
|
local file_paths = {}
|
||||||
|
for _, item in ipairs(harpoon_files.items) do
|
||||||
|
table.insert(file_paths, item.value)
|
||||||
|
end
|
||||||
|
|
||||||
|
require('telescope.pickers')
|
||||||
|
.new({}, {
|
||||||
|
prompt_title = 'Harpoon',
|
||||||
|
finder = require('telescope.finders').new_table {
|
||||||
|
results = file_paths,
|
||||||
|
},
|
||||||
|
previewer = conf.file_previewer {},
|
||||||
|
sorter = conf.generic_sorter {},
|
||||||
|
})
|
||||||
|
:find()
|
||||||
|
end
|
||||||
|
|
||||||
|
vim.keymap.set('n', '<C-e>', function()
|
||||||
|
toggle_telescope(harpoon:list())
|
||||||
|
end, { desc = 'Open harpoon window' })
|
||||||
|
end,
|
||||||
|
}
|
|
@ -3,90 +3,18 @@
|
||||||
--
|
--
|
||||||
-- See the kickstart.nvim README for more information
|
-- See the kickstart.nvim README for more information
|
||||||
return {
|
return {
|
||||||
|
|
||||||
|
-- multi line
|
||||||
|
{ 'mg979/vim-visual-multi' },
|
||||||
|
|
||||||
|
--tag bar to se files content on side pannel
|
||||||
{
|
{
|
||||||
'ThePrimeagen/harpoon',
|
'preservim/tagbar',
|
||||||
branch = 'harpoon2',
|
|
||||||
|
|
||||||
dependencies = { 'nvim-lua/plenary.nvim' },
|
|
||||||
config = function()
|
config = function()
|
||||||
local harpoon = require 'harpoon'
|
vim.keymap.set({ 'n' }, '<leader>tt', '<cmd>Tagbar<CR>', { desc = '[T]oggle [T]agbar' })
|
||||||
harpoon:setup()
|
|
||||||
vim.keymap.set({ 'n' }, '<leader>a', function()
|
|
||||||
harpoon:list():append()
|
|
||||||
end, { desc = '[A]ppend File to harpoon' })
|
|
||||||
vim.keymap.set('n', '<C-h>', function()
|
|
||||||
harpoon.ui:toggle_quick_menu(harpoon:list())
|
|
||||||
end, { desc = '[H]arpoon quick menu' })
|
|
||||||
|
|
||||||
vim.keymap.set('n', '<C-s>', function()
|
|
||||||
harpoon:list():select(1)
|
|
||||||
end)
|
|
||||||
vim.keymap.set('n', '<C-t>', function()
|
|
||||||
harpoon:list():select(2)
|
|
||||||
end)
|
|
||||||
vim.keymap.set('n', '<C-g>', function()
|
|
||||||
harpoon:list():select(3)
|
|
||||||
end)
|
|
||||||
vim.keymap.set('n', '<C-b>', function()
|
|
||||||
harpoon:list():select(4)
|
|
||||||
end)
|
|
||||||
|
|
||||||
-- Toggle previous & next buffers stored within Harpoon list
|
|
||||||
vim.keymap.set('n', '<C-p>', function()
|
|
||||||
harpoon:list():next()
|
|
||||||
end)
|
|
||||||
vim.keymap.set('n', '<C-n>', function()
|
|
||||||
harpoon:list():prev()
|
|
||||||
end)
|
|
||||||
local conf = require('telescope.config').values
|
|
||||||
local function toggle_telescope(harpoon_files)
|
|
||||||
local file_paths = {}
|
|
||||||
for _, item in ipairs(harpoon_files.items) do
|
|
||||||
table.insert(file_paths, item.value)
|
|
||||||
end
|
|
||||||
|
|
||||||
require('telescope.pickers')
|
|
||||||
.new({}, {
|
|
||||||
prompt_title = 'Harpoon',
|
|
||||||
finder = require('telescope.finders').new_table {
|
|
||||||
results = file_paths,
|
|
||||||
},
|
|
||||||
previewer = conf.file_previewer {},
|
|
||||||
sorter = conf.generic_sorter {},
|
|
||||||
})
|
|
||||||
:find()
|
|
||||||
end
|
|
||||||
|
|
||||||
vim.keymap.set('n', '<C-e>', function()
|
|
||||||
toggle_telescope(harpoon:list())
|
|
||||||
end, { desc = 'Open harpoon window' })
|
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
{
|
|
||||||
'ellisonleao/carbon-now.nvim',
|
--Terminal
|
||||||
lazy = true,
|
-- { 'akinsho/toggleterm.nvim', version = '*', config = true },
|
||||||
cmd = 'CarbonNow',
|
|
||||||
-- @param opts cn.ConfigSchema
|
|
||||||
opts = {
|
|
||||||
base_url = 'https://carbon.now.sh/',
|
|
||||||
open_cmd = 'xdg-open',
|
|
||||||
options = {
|
|
||||||
bg = 'gray',
|
|
||||||
drop_shadow_blur = '68px',
|
|
||||||
drop_shadow = false,
|
|
||||||
drop_shadow_offset_y = '20px',
|
|
||||||
font_family = 'JetBrains Mono',
|
|
||||||
font_size = '16px',
|
|
||||||
line_height = '124%',
|
|
||||||
line_numbers = true,
|
|
||||||
theme = 'verminal',
|
|
||||||
titlebar = 'Made with carbon-now.nvim',
|
|
||||||
watermark = false,
|
|
||||||
width = '680',
|
|
||||||
window_theme = 'sharp',
|
|
||||||
padding_horizontal = '0px',
|
|
||||||
padding_vertical = '0px',
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue