From 75bc8f752f53892189d8d49818fe6569ad589aa6 Mon Sep 17 00:00:00 2001 From: Filippo Berto Date: Thu, 27 Jun 2024 13:44:52 +0200 Subject: [PATCH] Neovim: obsidian plugin --- modules/hm/vim.nix | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/modules/hm/vim.nix b/modules/hm/vim.nix index 4076703..151a287 100644 --- a/modules/hm/vim.nix +++ b/modules/hm/vim.nix @@ -8,6 +8,8 @@ let vp = pkgs.vimPlugins; in { vimdiffAlias = true; plugins = [ + vp.plenary-nvim + # # Git related plugins # vp.fugitive # vp.rhubarb @@ -309,6 +311,26 @@ let vp = pkgs.vimPlugins; in { vim.keymap.set("n", "xl", function() require("trouble").toggle("loclist") end) ''; } + + { + plugin = vp.obsidian-nvim; + type = "lua"; + config = '' + require('obsidian').setup({ + workspaces = { + { name = "appunti", path = "~/Documenti/Git/Obsidian/appunti" } + }, + templates = { folder = "Templates", date_format = "%Y-%m-%d-%a", time_format = "%H:%M" }, + attachments = { img_folder = "Assets/" }, + daily_notes = { + folder = "Note of the day", + default_tags = { }, + alias_format = "%Y-%m-%d", + template = "Note of the day" + } + }) + ''; + } ]; # settings = { ignorecase = true; }; # coc.enable = true; @@ -352,6 +374,9 @@ let vp = pkgs.vimPlugins; in { -- Numbers o.number = true + -- Obisidan requirement + o.conceallevel = 1 + -- disable nvim intro -- opt.shortmess:append "sI"