Skip to content

Commit

Permalink
feat(nvide): add neovide
Browse files Browse the repository at this point in the history
  • Loading branch information
Fernando Corrêa de Oliveira committed Oct 24, 2024
1 parent 4bbd272 commit ec3c6e8
Show file tree
Hide file tree
Showing 6 changed files with 70 additions and 30 deletions.
24 changes: 24 additions & 0 deletions init.lua
Original file line number Diff line number Diff line change
@@ -1,3 +1,23 @@
if vim.g.neovide then
vim.g.neovide_fullscreen = true
vim.g.neovide_cursor_animation_length = 0
vim.g.neovide_cursor_trail_size = 0
vim.g.neovide_cursor_animate_command_line = false
vim.g.neovide_cursor_vfx_mode = ''

vim.env.PATH = vim.env.HOME
.. '/bin:/usr/local/bin:'
.. vim.env.HOME
.. '/nvim-macos/bin/:'
.. vim.env.HOME
.. '/rakudo/install/bin:'
.. vim.env.HOME
.. '/zef/bin:'
.. vim.env.HOME
.. '/rakudo/install/share/perl6/site/bin:'
.. vim.env.PATH
end

--[[
=====================================================================
Expand Down Expand Up @@ -250,5 +270,9 @@ vim.api.nvim_set_keymap('n', '[b', ':bprev<CR>', { noremap = true, silent = true
vim.api.nvim_set_keymap('o', 'A', ':normal ggVGo<CR>', { noremap = true, silent = true })
vim.api.nvim_set_keymap('v', 'A', 'Gogg', { noremap = true, silent = true })

vim.api.nvim_set_keymap('n', '<leader>zi', '<c-w>_ | <c-w>|', { noremap = true, silent = true })
vim.api.nvim_set_keymap('n', '<leader>zo', '<c-w>=', { noremap = true, silent = true })
vim.api.nvim_set_keymap('n', '<leader>bd', ':bdelete<CR>', { noremap = true, silent = true })

-- The line beneath this is called `modeline`. See `:help modeline`
-- vim: ts=2 sts=2 sw=2 et
2 changes: 1 addition & 1 deletion lua/custom/plugins/bujo.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ return {
dev = true,
lazy = false,
opts = {
symbols = { '', '🔨', '', '🗓️', '👉', '🗑️', '💡' },
-- symbols = { '☐', '🔨', '✅', '🗓️', '👉', '🗑️', '💡' },
},
}
37 changes: 22 additions & 15 deletions lua/custom/plugins/colorscheme.lua
Original file line number Diff line number Diff line change
@@ -1,17 +1,24 @@
return { -- You can easily change to a different colorscheme.
-- Change the name of the colorscheme plugin below, and then
-- change the command in the config to whatever the name of that colorscheme is.
--
-- If you want to see what colorschemes are already installed, you can use `:Telescope colorscheme`.
'folke/tokyonight.nvim',
priority = 1000, -- Make sure to load this before all the other start plugins.
init = function()
-- Load the colorscheme here.
-- Like many other themes, this one has different styles, and you could load
-- any other, such as 'tokyonight-storm', 'tokyonight-moon', or 'tokyonight-day'.
vim.cmd.colorscheme 'tokyonight-night'
return {
{ -- You can easily change to a different colorscheme.
-- Change the name of the colorscheme plugin below, and then
-- change the command in the config to whatever the name of that colorscheme is.
--
-- If you want to see what colorschemes are already installed, you can use `:Telescope colorscheme`.
'folke/tokyonight.nvim',
priority = 1000, -- Make sure to load this before all the other start plugins.
init = function()
-- Load the colorscheme here.
-- Like many other themes, this one has different styles, and you could load
-- any other, such as 'tokyonight-storm', 'tokyonight-moon', or 'tokyonight-day'.
vim.cmd.colorscheme 'tokyonight-night'

-- You can configure highlights by doing something like:
vim.cmd.hi 'Comment gui=none'
end,
-- You can configure highlights by doing something like:
-- vim.cmd.hi 'Comment gui=none'
end,
},
{
'dgox16/oldworld.nvim',
lazy = false,
priority = 1000,
},
}
6 changes: 6 additions & 0 deletions lua/custom/plugins/conventional_commit.lua
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,13 @@ vim.api.nvim_create_autocmd('FileType', {
'test',
'chore',
}, { prompt = 'Change type' }, function(type)
if type == nil then
return
end
vim.ui.input({ prompt = 'Context' }, function(context)
if context == nil then
return
end
local commit_message = type
if context ~= '' then
commit_message = commit_message .. '(' .. context .. ')'
Expand Down
2 changes: 1 addition & 1 deletion lua/custom/plugins/terminal.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ return {
version = '*',
config = function()
require('toggleterm').setup {
open_mapping = '<leader>TT',
-- open_mapping = '<leader>TT',
}
vim.api.nvim_set_keymap('n', '<S-CR>', ':TermExec cmd="⏎"<CR>', { desc = 'Send new line to terminal', noremap = true, silent = true })
vim.api.nvim_set_keymap('n', '<Leader>T ', ':TermSelect<cr>', { desc = 'Open terminal', noremap = true, silent = true })
Expand Down
29 changes: 16 additions & 13 deletions lua/custom/plugins/whichkey.lua
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,23 @@ return { -- Useful plugin to show you pending keybinds.
'folke/which-key.nvim',
event = 'VimEnter', -- Sets the loading event to 'VimEnter'
config = function() -- This is the function that runs, AFTER loading
require('which-key').setup()
local wk = require 'which-key'
wk.setup()

-- Document existing key chains
require('which-key').add {
{ '<leader>c', group = '[C]ode' },
{ '<leader>d', group = '[D]ocument' },
{ '<leader>o', group = '[N]org-mode' },
{ '<leader>n', group = '[N]org-roam' },
{ '<leader>r', group = '[R]ename' },
{ '<leader>s', group = '[S]earch' },
{ '<leader>w', group = '[W]orkspace' },
{ '<leader>t', group = '[T]oggle' },
{ '<leader>T', group = '[T]erminal' },
{ '<leader>h', group = 'Git [H]unk', mode = { 'n', 'v' } },
}
if wk.add then
wk.add {
{ '<leader>c', group = '[C]ode' },
{ '<leader>d', group = '[D]ocument' },
{ '<leader>o', group = '[N]org-mode' },
{ '<leader>n', group = '[N]org-roam' },
{ '<leader>r', group = '[R]ename' },
{ '<leader>s', group = '[S]earch' },
{ '<leader>w', group = '[W]orkspace' },
{ '<leader>t', group = '[T]oggle' },
{ '<leader>T', group = '[T]erminal' },
{ '<leader>h', group = 'Git [H]unk', mode = { 'n', 'v' } },
}
end
end,
}

0 comments on commit ec3c6e8

Please sign in to comment.