aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--config/nvim/init.lua18
-rw-r--r--config/nvim/lazy-lock.json30
-rw-r--r--config/nvim/lua/neorg_config.lua3
-rw-r--r--config/nvim/lua/plugins.lua98
-rw-r--r--config/nvim/lua/treesitter_config.lua30
-rw-r--r--config/tmux/tmux.conf6
6 files changed, 125 insertions, 60 deletions
diff --git a/config/nvim/init.lua b/config/nvim/init.lua
index 8c4f304..1c57f00 100644
--- a/config/nvim/init.lua
+++ b/config/nvim/init.lua
@@ -50,11 +50,16 @@ vim.keymap.set('n', '<C-n>', function()
end)
-- Move lines / blocks up and down using Ctrl + Shift
-vim.keymap.set('n', '<C-S-j>', ':m .+1<CR>==')
-vim.keymap.set('n', '<C-S-k>', ':m .-2<CR>==')
+vim.keymap.set('n', '<C-S-j>', function()
+ return '<Cmd>m .+' .. vim.v.count1 .. '<CR>=='
+end, { expr = true, silent = true })
+
+vim.keymap.set('n', '<C-S-k>', function()
+ return '<Cmd>m .-' .. (vim.v.count1 + 1) .. '<CR>=='
+end, { expr = true, silent = true })
vim.keymap.set('i', '<C-S-j>', '<Esc>:m .+1<CR>==gi')
vim.keymap.set('i', '<C-S-k>', '<Esc>:m .-2<CR>==gi')
-vim.keymap.set('v', '<C-S-j>', ':m \'>+1<CR>gv=gv')
+vim.keymap.set('v', '<C-S-j>', ':m \'>+2<CR>gv=gv')
vim.keymap.set('v', '<C-S-k>', ':m \'<-2<CR>gv=gv')
-- Navigate the location list
@@ -80,7 +85,7 @@ vim.api.nvim_create_autocmd({'BufNewFile', 'BufRead'}, {
vim.api.nvim_create_autocmd({'BufNewFile', 'BufRead'}, {
pattern = {'.plan'},
- callback = function () vim.opt.filetype = 'markdown' end
+ callback = function () vim.opt.filetype = 'norg' end
})
-------------------------------------------------------------------------------
@@ -95,9 +100,6 @@ pcall(require, 'init_local')
vim.keymap.set('n', '<c-P>',
"<cmd>lua require('fzf-lua').files({cmd = \"rg --files --hidden -g !.git\"})<CR>", { silent = true })
--- Toggle Autosave
-vim.api.nvim_set_keymap('n', '<leader>n', ':ASToggle<CR>', {})
-
-- Svelte Config
vim.g.vim_svelte_plugin_use_typescript = true
@@ -112,4 +114,4 @@ require('plugins')
require('treesitter_config')
require('lsp')
require('dap_config')
-require('calendar_tools')
+require('neorg_config')
diff --git a/config/nvim/lazy-lock.json b/config/nvim/lazy-lock.json
index 4a159ca..f10c836 100644
--- a/config/nvim/lazy-lock.json
+++ b/config/nvim/lazy-lock.json
@@ -1,26 +1,34 @@
{
- "blink.cmp": { "branch": "main", "commit": "4b18c32adef2898f95cdef6192cbd5796c1a332d" },
+ "blink.cmp": { "branch": "main", "commit": "78336bc89ee5365633bcf754d93df01678b5c08f" },
"friendly-snippets": { "branch": "main", "commit": "6cd7280adead7f586db6fccbd15d2cac7e2188b9" },
- "fzf-lua": { "branch": "main", "commit": "d9508cc1d05ffcdc91a32dfd38fc1013a56b20da" },
+ "fzf-lua": { "branch": "main", "commit": "8223eb24a7adf72c4b24e04b751486b492775414" },
"gemini.vim": { "branch": "master", "commit": "c9efb59c97b71c28d4678c79fd21fbdd3a69d196" },
+ "image.nvim": { "branch": "master", "commit": "da2be65c153ba15a14a342b05591652a6df70d58" },
"jannotate.nvim": { "branch": "main", "commit": "6bb5fb17d7da5437ea27a6079216cc5663d5e717" },
"lazy.nvim": { "branch": "main", "commit": "306a05526ada86a7b30af95c5cc81ffba93fef97" },
- "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" },
+ "lazydev.nvim": { "branch": "main", "commit": "ff2cbcba459b637ec3fd165a2be59b7bbaeedf0d" },
+ "lua-utils.nvim": { "branch": "main", "commit": "e565749421f4bbb5d2e85e37c3cef9d56553d8bd" },
"marginalie.nvim": { "branch": "main", "commit": "0f7fa3e0b558eae20dd56d6ff62d08595a1b88d5" },
"neogen": { "branch": "main", "commit": "23e7e9f883d01289ebd90e98025acc860ea26366" },
- "nota.nvim": { "branch": "main", "commit": "503bfaa93968986a9df5376c4543207c70dd2a07" },
+ "neorg": { "branch": "main", "commit": "a09e0bb9b32e2d0406d4503ae8c1a7ad2ca83eae" },
+ "neorg-interim-ls": { "branch": "main", "commit": "898898f48fe7a2364d99d32f0dfd95dab5f8591f" },
+ "nota.nvim": { "branch": "main", "commit": "4f22d307fb9fd0f44f6e6767b97869a238f18160" },
+ "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" },
"nvim-autopairs": { "branch": "master", "commit": "59bce2eef357189c3305e25bc6dd2d138c1683f5" },
- "nvim-dap": { "branch": "master", "commit": "a9d8cb68ee7184111dc66156c4a2ebabfbe01bc5" },
- "nvim-dap-ui": { "branch": "master", "commit": "cf91d5e2d07c72903d052f5207511bf7ecdb7122" },
- "nvim-lspconfig": { "branch": "master", "commit": "d8bf4c47385340ab2029402201d4d7c9f99f437a" },
+ "nvim-dap": { "branch": "master", "commit": "45a69eba683a2c448dd9ecfc4de89511f0646b5f" },
+ "nvim-dap-ui": { "branch": "master", "commit": "1a66cabaa4a4da0be107d5eda6d57242f0fe7e49" },
+ "nvim-lspconfig": { "branch": "master", "commit": "e146efacbafed3789ac568abcc5a981c5decaa58" },
"nvim-nio": { "branch": "master", "commit": "21f5324bfac14e22ba26553caf69ec76ae8a7662" },
- "nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" },
+ "nvim-treesitter": { "branch": "main", "commit": "4916d6592ede8c07973490d9322f187e07dfefac" },
"nvim-treesitter-endwise": { "branch": "master", "commit": "8fe8a95630f4f2c72a87ba1927af649e0bfaa244" },
"oil.nvim": { "branch": "master", "commit": "0fcc83805ad11cf714a949c98c605ed717e0b83e" },
- "oleoboard.nvim": { "branch": "main", "commit": "3652b39db3a8faca3fb767ace799479124bc79f3" },
+ "pathlib.nvim": { "branch": "main", "commit": "57e5598af6fe253761c1b48e0b59b7cd6699e2c1" },
"snes-syntax-vim": { "branch": "master", "commit": "a6a699c8905f7b6119bf91e44f960667d9f03d59" },
- "tree-sitter-api-notation": { "branch": "main", "commit": "3113c6077d9ed1e662a891714ac00e1ee3bb7657" },
- "tree-sitter-wmap": { "branch": "main", "commit": "c01881ae8910f11653e69d7bbded07e4413991bc" },
+ "sniprun": { "branch": "master", "commit": "6416f98924018385f7f5ebfe8dc773a4482426e4" },
+ "tree-sitter-api-notation": { "branch": "main", "commit": "9fecd8fabdc688b125f3a5e36060a7577549b71e" },
+ "tree-sitter-norg": { "branch": "main", "commit": "d7edfaf89198aab652c7a1f0f818196efedaccfb" },
+ "tree-sitter-norg-meta": { "branch": "main", "commit": "729d4e54fb881ba0ddf0f925ec78401354c7c6db" },
+ "tree-sitter-wmap": { "branch": "main", "commit": "ac6e7ae00b8d5568b216542d23528be1dfff0ea4" },
"undotree": { "branch": "master", "commit": "6fa6b57cda8459e1e4b2ca34df702f55242f4e4d" },
"vim-indent-object": { "branch": "master", "commit": "8ab36d5ec2a3a60468437a95e142ce994df598c6" },
"vim-togglelist": { "branch": "master", "commit": "48f0d30292efdf20edc883e61b121e6123e03df7" },
diff --git a/config/nvim/lua/neorg_config.lua b/config/nvim/lua/neorg_config.lua
new file mode 100644
index 0000000..79fb8a1
--- /dev/null
+++ b/config/nvim/lua/neorg_config.lua
@@ -0,0 +1,3 @@
+vim.wo.foldlevel = 99
+vim.wo.conceallevel = 2
+vim.keymap.set("n", "gC", "<cmd>Neorg toc<CR>", {})
diff --git a/config/nvim/lua/plugins.lua b/config/nvim/lua/plugins.lua
index 61d329d..ef68eee 100644
--- a/config/nvim/lua/plugins.lua
+++ b/config/nvim/lua/plugins.lua
@@ -1,12 +1,14 @@
+vim.g.mapleader = ' '
+vim.g.maplocalleader = ';'
local lazypath = vim.fn.stdpath('data') .. '/lazy/lazy.nvim' if not vim.loop.fs_stat(lazypath) then
- vim.fn.system({
- 'git',
- 'clone',
- '--filter=blob:none',
- 'https://github.com/folke/lazy.nvim.git',
- '--branch=stable', -- latest stable release
- lazypath,
- })
+vim.fn.system({
+ 'git',
+ 'clone',
+ '--filter=blob:none',
+ 'https://github.com/folke/lazy.nvim.git',
+ '--branch=stable', -- latest stable release
+ lazypath,
+})
end
vim.opt.rtp:prepend(lazypath)
@@ -80,7 +82,12 @@ require('lazy').setup({
},
-- Treesitter
- 'nvim-treesitter/nvim-treesitter',
+ {
+ 'nvim-treesitter/nvim-treesitter',
+ lazy = false,
+ build = ':TSUpdate',
+ branch = 'main'
+ },
'https://git.sr.ht/~rbdr/tree-sitter-api-notation',
'https://git.sr.ht/~rbdr/tree-sitter-wmap',
@@ -103,7 +110,11 @@ require('lazy').setup({
['<S-Tab>'] = { 'snippet_backward', 'select_prev', 'fallback' },
},
sources = {
- default = { 'lsp', 'path', 'snippets', 'buffer' },
+ default = { 'lsp', 'path', 'buffer', 'snippets' },
+ per_filetype = {
+ markdown = { 'lsp'},
+ norg = { 'lsp'}
+ }
},
fuzzy = { implementation = "prefer_rust_with_warning" },
},
@@ -119,6 +130,13 @@ require('lazy').setup({
'mbbill/undotree',
'milkypostman/vim-togglelist',
{
+ "3rd/image.nvim",
+ build = false,
+ opts = {
+ processor = "magick_cli",
+ }
+ },
+ {
'folke/which-key.nvim',
event = 'VeryLazy',
init = function()
@@ -136,9 +154,65 @@ require('lazy').setup({
}
}
},
+ {
+ 'nvim-neorg/neorg',
+ lazy = false,
+ version = "*",
+ config = true,
+ dependencies = {
+ 'nvim-neorg/tree-sitter-norg',
+ 'nvim-neorg/tree-sitter-norg-meta',
+ },
+ opts = {
+ load = {
+ ["core.defaults"] = {},
+ ["core.concealer"] = {},
+ ["core.pivot"] = {},
+ ["core.latex.renderer"] = {},
+ ["core.journal"] = {
+ config = {
+ journal_folder = "periodic/daily",
+ strategy = "flat",
+ template_name = "../../templates/daily.norg",
+ workspace = "brain",
+ },
+ },
+ ["core.dirman"] = {
+ config = {
+ workspaces = {
+ brain = "~/brain",
+ },
+ default_workspace = "brain",
+ }
+ },
+ ["external.interim-ls"] = {},
+ ["core.completion"] = {
+ config = { engine = { module_name = "external.lsp-completion" } },
+ },
+ }
+}
+ },
+ {
+ "michaelb/sniprun",
+ branch = "master",
- 'https://git.sr.ht/~rbdr/nota.nvim',
- 'https://git.sr.ht/~rbdr/oleoboard.nvim',
+ build = "sh install.sh",
+ -- do 'sh install.sh 1' if you want to force compile locally
+ -- (instead of fetching a binary from the github release). Requires Rust >= 1.65
+
+ config = function()
+ require("sniprun").setup({
+ -- your options
+ })
+ end,
+ },
+ 'benlubas/neorg-interim-ls',
+ {
+ 'https://git.sr.ht/~rbdr/nota.nvim',
+ opts = {
+ norg = true,
+ }
+ },
'https://git.sr.ht/~rbdr/jannotate.nvim',
'https://git.sr.ht/~rbdr/marginalie.nvim'
})
diff --git a/config/nvim/lua/treesitter_config.lua b/config/nvim/lua/treesitter_config.lua
index 2502859..70f251f 100644
--- a/config/nvim/lua/treesitter_config.lua
+++ b/config/nvim/lua/treesitter_config.lua
@@ -1,7 +1,4 @@
-require'nvim-treesitter.configs'.setup {
- -- A list of parser names, or "all" (the five listed parsers should always be installed)
- ensure_installed = {
- 'api_notation',
+require('nvim-treesitter').install {
'bash',
'css',
'dart',
@@ -28,28 +25,5 @@ require'nvim-treesitter.configs'.setup {
'toml',
'tsx',
'typescript',
- 'wmap',
'yaml'
- },
-
- sync_install = false,
- auto_install = true,
-
- endwise = {
- enable = true
- },
-
- highlight = {
- enable = true,
-
- disable = function(lang, buf)
- local max_filesize = 100 * 1024 -- 100 KB
- local ok, stats = pcall(vim.loop.fs_stat, vim.api.nvim_buf_get_name(buf))
- if ok and stats and stats.size > max_filesize then
- return true
- end
- end,
-
- additional_vim_regex_highlighting = false,
- },
-}
+ }
diff --git a/config/tmux/tmux.conf b/config/tmux/tmux.conf
index c319f99..bdda0ff 100644
--- a/config/tmux/tmux.conf
+++ b/config/tmux/tmux.conf
@@ -26,7 +26,7 @@ set-window-option -g window-status-activity-style bold,underscore
# Set Activity monitoring.
setw -g monitor-activity on
-set -g visual-activity on
+set -g visual-activity off
# Vi keys in copy mode.
setw -g mode-keys vi
@@ -61,3 +61,7 @@ set -g set-titles-string '󰝘 #{session_name}'
# Clock
set -g clock-mode-style 24-with-seconds
+
+# Config for image rendering.
+set -gq allow-passthrough on
+set-option -g focus-events on