Compare commits
5 Commits
87ab333ec9
...
271a18b3a8
| Author | SHA1 | Date | |
|---|---|---|---|
| 271a18b3a8 | |||
| b185b7e2a8 | |||
| fb16ca882b | |||
| f47c861331 | |||
| 6f5a898f3c |
@@ -1,10 +1,12 @@
|
|||||||
local diary_open = function(opts)
|
local diary_open = function(opts)
|
||||||
local date = opts.args ~= '' and opts.args or os.date('%Y-%m-%d')
|
local date = opts.args ~= '' and opts.args or os.date('%Y-%m-%d')
|
||||||
local year, month = date:match('(%d%d%d%d)-(%d%d)')
|
local year, month = date:match('(%d%d%d%d)-(%d%d)')
|
||||||
local file = string.format('~/.diary/asciidoc/%s/diary-%s-%s.adoc', year, year, month)
|
local folder = string.format('~/.diary/asciidoc/%s', year)
|
||||||
|
vim.fn.mkdir(folder, "p")
|
||||||
|
local file = string.format('%s/diary-%s-%s.adoc', folder, year, month)
|
||||||
print("file is:", file)
|
print("file is:", file)
|
||||||
vim.cmd('e ' .. file)
|
vim.cmd('e ' .. file)
|
||||||
vim.cmd('normal! G')
|
vim.cmd('normal! G') -- go to end of file
|
||||||
|
|
||||||
-- NOTE.2025-06-08 [1] and [2] should be replaced with snippet name, but I
|
-- NOTE.2025-06-08 [1] and [2] should be replaced with snippet name, but I
|
||||||
-- don't know how -- neither do grok nor chatgpt ...
|
-- don't know how -- neither do grok nor chatgpt ...
|
||||||
|
|||||||
@@ -9,7 +9,11 @@ vim.keymap.set('n', '<leader>fg', fzf.live_grep, { desc = "Grep" })
|
|||||||
vim.keymap.set('n', '<leader>fm', fzf.manpages, { desc = "Manpages" })
|
vim.keymap.set('n', '<leader>fm', fzf.manpages, { desc = "Manpages" })
|
||||||
vim.keymap.set('n', '<leader>fr', fzf.resume, { desc = "Resume last search" })
|
vim.keymap.set('n', '<leader>fr', fzf.resume, { desc = "Resume last search" })
|
||||||
vim.keymap.set('n', '<leader>fs', fzf.blines, { desc = "Search buffer" })
|
vim.keymap.set('n', '<leader>fs', fzf.blines, { desc = "Search buffer" })
|
||||||
|
vim.keymap.set('n', '<leader>f=', fzf.changes, { desc = "Changes" })
|
||||||
|
vim.keymap.set('n', '<leader>fR', fzf.registers, { desc = "Registers" })
|
||||||
|
vim.keymap.set('n', '<leader>fo', fzf.nvim_options, { desc = "NVim Options" })
|
||||||
vim.keymap.set('n', '<leader>ft', ":TodoFzfLua<CR>", { desc = "Todos" })
|
vim.keymap.set('n', '<leader>ft', ":TodoFzfLua<CR>", { desc = "Todos" })
|
||||||
|
vim.keymap.set('n', '<leader>fl', fzf.git_bcommits, { desc = "Git buffer log" })
|
||||||
|
|
||||||
-- use fzf buffer lines as default search
|
-- use fzf buffer lines as default search
|
||||||
vim.keymap.set('n', '<C-/>', fzf.blines, { desc = "Search buffer" })
|
vim.keymap.set('n', '<C-/>', fzf.blines, { desc = "Search buffer" })
|
||||||
@@ -17,7 +21,8 @@ vim.keymap.set('n', 'z=', fzf.spell_suggest, { desc = "Spelling suggestions" })
|
|||||||
|
|
||||||
-- open file manager and git
|
-- open file manager and git
|
||||||
vim.keymap.set('n', '<leader>g', ":Neogit<CR>", { desc = "Neogit" })
|
vim.keymap.set('n', '<leader>g', ":Neogit<CR>", { desc = "Neogit" })
|
||||||
vim.keymap.set('n', '<leader>T', ":Neotree reveal<CR>", { desc = "File Manager" })
|
vim.keymap.set('n', '<leader>T', ":Neotree reveal<CR>", { desc = "Neotree Files" })
|
||||||
|
vim.keymap.set('n', '<leader>F', ":Fyler kind=split_left<CR>", { desc = "Fyler Files" })
|
||||||
|
|
||||||
-- calendar
|
-- calendar
|
||||||
vim.keymap.set('n', '<leader>c', ":Calendar -split=horizontal -position=below -height=12<CR>", { desc = "Show calendar below" })
|
vim.keymap.set('n', '<leader>c', ":Calendar -split=horizontal -position=below -height=12<CR>", { desc = "Show calendar below" })
|
||||||
|
|||||||
@@ -103,6 +103,8 @@ local enable_this_lsp = {
|
|||||||
'kotlin_lsp', -- arch aur: kotlin-lsp-bin
|
'kotlin_lsp', -- arch aur: kotlin-lsp-bin
|
||||||
'lemminx', -- arch aur: lemminx
|
'lemminx', -- arch aur: lemminx
|
||||||
'clangd',
|
'clangd',
|
||||||
|
'basedpyright',
|
||||||
|
'wgsl_analyzer',
|
||||||
}
|
}
|
||||||
|
|
||||||
for l in pairs(enable_this_lsp) do
|
for l in pairs(enable_this_lsp) do
|
||||||
|
|||||||
@@ -125,8 +125,7 @@ require("lazy").setup({
|
|||||||
--
|
--
|
||||||
-- LSP manager and others
|
-- LSP manager and others
|
||||||
--
|
--
|
||||||
-- "williamboman/mason.nvim",
|
-- https://github.com/neovim/nvim-lspconfig
|
||||||
-- "williamboman/mason-lspconfig.nvim",
|
|
||||||
"neovim/nvim-lspconfig",
|
"neovim/nvim-lspconfig",
|
||||||
|
|
||||||
-- Nice plugin to show what LSPs are doing in the background (and others
|
-- Nice plugin to show what LSPs are doing in the background (and others
|
||||||
@@ -369,6 +368,9 @@ require("lazy").setup({
|
|||||||
-- workspaces, lightweight "projects"
|
-- workspaces, lightweight "projects"
|
||||||
{
|
{
|
||||||
"natecraddock/workspaces.nvim",
|
"natecraddock/workspaces.nvim",
|
||||||
|
dependencies = {
|
||||||
|
"ibhagwan/fzf-lua"
|
||||||
|
},
|
||||||
config = function()
|
config = function()
|
||||||
require("workspaces").setup {
|
require("workspaces").setup {
|
||||||
-- sort the list of workspaces by name after loading from the workspaces path.
|
-- sort the list of workspaces by name after loading from the workspaces path.
|
||||||
@@ -402,15 +404,15 @@ require("lazy").setup({
|
|||||||
|
|
||||||
|
|
||||||
-- TODO, WARN, HACK, PERF, NOTE, TEST and others highlighting and searching
|
-- TODO, WARN, HACK, PERF, NOTE, TEST and others highlighting and searching
|
||||||
-- {
|
{
|
||||||
-- "folke/todo-comments.nvim",
|
"folke/todo-comments.nvim",
|
||||||
-- dependencies = { "nvim-lua/plenary.nvim" },
|
dependencies = { "nvim-lua/plenary.nvim" },
|
||||||
-- opts = {
|
opts = {
|
||||||
-- -- your configuration comes here
|
-- your configuration comes here
|
||||||
-- -- or leave it empty to use the default settings
|
-- or leave it empty to use the default settings
|
||||||
-- -- refer to the configuration section below
|
-- refer to the configuration section below
|
||||||
-- }
|
}
|
||||||
-- },
|
},
|
||||||
|
|
||||||
-- highlight word under cursor
|
-- highlight word under cursor
|
||||||
{
|
{
|
||||||
@@ -504,5 +506,56 @@ require("lazy").setup({
|
|||||||
config = function() require('sqlua').setup() end
|
config = function() require('sqlua').setup() end
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
|
{
|
||||||
|
'sphamba/smear-cursor.nvim',
|
||||||
|
opts = {
|
||||||
|
-- cursor_color = "#ff4000",
|
||||||
|
cursor_color = "#8b0000",
|
||||||
|
stiffness = 1,
|
||||||
|
trailing_stiffness = 1,
|
||||||
|
trailing_exponent = 0,
|
||||||
|
matrix_pixel_threshold = 1,
|
||||||
|
damping = 0.9,
|
||||||
|
gradient_exponent = 0,
|
||||||
|
gamma = 1,
|
||||||
|
never_draw_over_target = true, -- if you want to actually see under the cursor
|
||||||
|
hide_target_hack = true, -- same
|
||||||
|
legacy_computing_symbols_support = true,
|
||||||
|
|
||||||
|
-- Only smear cursor when moving at least these distances
|
||||||
|
-- value of 2 inhibits smear while typing
|
||||||
|
min_horizontal_distance_smear = 2,
|
||||||
|
min_vertical_distance_smear = 2,
|
||||||
|
|
||||||
|
smear_insert_mode = false,
|
||||||
|
|
||||||
|
-- particles configuration
|
||||||
|
particles_enabled = true,
|
||||||
|
particle_spread = 1,
|
||||||
|
particles_per_second = 200,
|
||||||
|
particles_per_length = 50,
|
||||||
|
particle_max_lifetime = 800,
|
||||||
|
particle_max_initial_velocity = 20,
|
||||||
|
particle_velocity_from_cursor = 0.5,
|
||||||
|
particle_damping = 0.15,
|
||||||
|
particle_gravity = 50,
|
||||||
|
min_distance_emit_particles = 0,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
"A7Lavinraj/fyler.nvim",
|
||||||
|
dependencies = { "nvim-mini/mini.icons" },
|
||||||
|
branch = "stable", -- Use stable branch for production
|
||||||
|
opts = {
|
||||||
|
views = {
|
||||||
|
finder = {
|
||||||
|
delete_to_trash = true,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
-- new plugins BEFORE here
|
-- new plugins BEFORE here
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user