mirror of
https://github.com/iofq/nvim.nix.git
synced 2026-01-23 08:55:16 -06:00
org mode
This commit is contained in:
parent
2bab00d2e3
commit
f47fc0f76f
8 changed files with 118 additions and 8 deletions
|
|
@ -5,6 +5,7 @@ return {
|
|||
dependencies = {
|
||||
'mikavilpas/blink-ripgrep.nvim',
|
||||
'fang2hou/blink-copilot',
|
||||
'nvim-orgmode/orgmode',
|
||||
},
|
||||
opts = {
|
||||
fuzzy = {
|
||||
|
|
@ -23,6 +24,9 @@ return {
|
|||
'ripgrep',
|
||||
'copilot',
|
||||
},
|
||||
per_filetype = {
|
||||
org = { 'orgmode' },
|
||||
},
|
||||
providers = {
|
||||
snippets = {
|
||||
score_offset = -20,
|
||||
|
|
@ -47,6 +51,11 @@ return {
|
|||
},
|
||||
},
|
||||
},
|
||||
orgmode = {
|
||||
name = 'Orgmode',
|
||||
module = 'orgmode.org.autocompletion.blink',
|
||||
fallbacks = { 'buffer' },
|
||||
},
|
||||
},
|
||||
},
|
||||
cmdline = {
|
||||
|
|
|
|||
|
|
@ -51,6 +51,26 @@ return {
|
|||
noremap = true,
|
||||
desc = 'git diff overlay',
|
||||
},
|
||||
{
|
||||
'<leader>gd',
|
||||
function()
|
||||
return MiniGit.show_at_cursor()
|
||||
end,
|
||||
noremap = true,
|
||||
desc = 'git show at cursor',
|
||||
},
|
||||
{
|
||||
'<leader>gb',
|
||||
'<Cmd>Git blame -- %<CR>',
|
||||
noremap = true,
|
||||
desc = 'git blame',
|
||||
},
|
||||
{
|
||||
'<leader>gg',
|
||||
':Git ',
|
||||
noremap = true,
|
||||
desc = 'git command',
|
||||
},
|
||||
},
|
||||
config = function()
|
||||
require('mini.basics').setup { mappings = { windows = true } }
|
||||
|
|
@ -96,6 +116,7 @@ return {
|
|||
prefix = 'gR',
|
||||
},
|
||||
}
|
||||
require('mini.git').setup()
|
||||
setup_pairs {
|
||||
modes = { insert = true, command = true, terminal = false },
|
||||
skip_next = [=[[%w%%%'%[%"%.%`%$]]=],
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ return {
|
|||
'MeanderingProgrammer/render-markdown.nvim',
|
||||
event = 'VeryLazy',
|
||||
opts = {
|
||||
ft = { 'markdown', 'codecompanion' },
|
||||
file_types = { 'markdown', 'codecompanion' },
|
||||
},
|
||||
},
|
||||
{
|
||||
|
|
@ -109,6 +109,7 @@ return {
|
|||
'neogit',
|
||||
'native_lsp',
|
||||
'diagnostic',
|
||||
'modes',
|
||||
},
|
||||
},
|
||||
},
|
||||
|
|
@ -148,4 +149,47 @@ return {
|
|||
},
|
||||
},
|
||||
{ 'ThePrimeagen/refactoring.nvim', event = 'VeryLazy', config = true },
|
||||
{
|
||||
'nvim-orgmode/orgmode',
|
||||
event = 'VeryLazy',
|
||||
ft = { 'org' },
|
||||
dependencies = 'nvim-treesitter',
|
||||
keys = {
|
||||
{
|
||||
'<leader>oR',
|
||||
'<cmd>e ~/orgfiles/refile.org<CR>',
|
||||
desc = 'open org refile',
|
||||
},
|
||||
},
|
||||
config = function()
|
||||
require('orgmode').setup {
|
||||
org_agenda_files = '~/orgfiles/**/*',
|
||||
org_default_notes_file = '~/orgfiles/refile.org',
|
||||
org_todo_keywords = {
|
||||
'TODO',
|
||||
'IN_PROGRESS',
|
||||
'BLOCKED',
|
||||
'|',
|
||||
'DONE',
|
||||
'NOT DOING',
|
||||
},
|
||||
org_capture_templates = {
|
||||
l = {
|
||||
description = 'Work Log',
|
||||
template = '* %?',
|
||||
target = '~/orgfiles/worklog.org',
|
||||
},
|
||||
},
|
||||
}
|
||||
vim.api.nvim_create_autocmd('FileType', {
|
||||
pattern = 'org',
|
||||
callback = function()
|
||||
vim.keymap.set({ 'n', 'i' }, '\\\\', '<cmd>lua require("orgmode").action("org_mappings.meta_return")<CR>', {
|
||||
silent = true,
|
||||
buffer = true,
|
||||
})
|
||||
end,
|
||||
})
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,6 +28,7 @@ return {
|
|||
config = function()
|
||||
require('nvim-treesitter.configs').setup {
|
||||
ensure_installed = {},
|
||||
ignore_install = { 'org' },
|
||||
auto_install = false,
|
||||
highlight = {
|
||||
enable = true,
|
||||
|
|
@ -56,12 +57,12 @@ return {
|
|||
goto_next_start = {
|
||||
[']a'] = '@parameter.inner',
|
||||
[']f'] = '@function.outer',
|
||||
['}'] = '@statement.outer',
|
||||
[']]'] = '@statement.outer',
|
||||
},
|
||||
goto_previous_start = {
|
||||
['[a'] = '@parameter.inner',
|
||||
['[f'] = '@function.outer',
|
||||
['{'] = '@statement.outer',
|
||||
['[['] = '@statement.outer',
|
||||
},
|
||||
},
|
||||
swap = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue