I wanted a truly uncomplicated note taking setup. Nothing overwrought, just an easy way to pop open a project specific location for project notes, a global location for ongoing todos or notes, and another global location I can use for scratch files.
A global file or directory, opened with Nota.open_global
.
A global scratch file or directory, opened with Nota.open_scratch
.
A file or directory at a path relative to the current working directory, opened with Nota.open_local
.
Directories you specify in any configured path that do not yet exist will be created the first time you run the relevant command.
Here's the open_local
command being used where the configuration specifies a file notes.md
in the project root directory, and vertical split.
nota-local-file-demo.mp4
Here's the open_local
command being used where the configuration specifies a directory notes/
from the project root directory, and vertical split.
nota-local-dir-demo.mp4
-- Nota
{
"ahollister/nota.nvim",
config = function()
require("nota").setup({
global_path = "/Users/johnsmith/nota/notes.md",
scratch_path = "/Users/johnsmith/nota/scratch.md",
local_path = "project-notes/notes.md",
vertical_split = true
})
end
}
N.B: I haven't tested this with lots of file navigation plugins, (just Oil.nvim since that's what I am using), but the function that opens these directories is just the split
or vsplit
command so I don't expect it should break.
-- Nota
{
"ahollister/nota.nvim",
config = function()
require("nota").setup({
global_path = "/Users/johnsmith/nota/notes/",
scratch_path = "/Users/johnsmith/nota/scratch/",
local_path = "project-notes/",
vertical_split = true
})
end
}
The path for the global file or directory you wish to use.
The path for the global scratch file or directory you wish to use.
The filename you want to use for your project-local note file or directory.
Whether you want to open the location in a vertical split, by default it will use a horizontal split.
:Nota open_global
- Opens the global location.
:Nota open_scratch
- Opens the global scratch location.
:Nota open_local
- Opens the local location.