1Password secure notes editor
Closed this issue · 3 comments
We should be able to load secure notes items into a buffer, set vim.bo.filetype = 'markdown'
(since I think 1Password secure notes uses markdown), set the vim.bo.buftype = 'nofile'
, and edit 1Password secure notes in Neovim.
As for updating, there's one of two approaches we can do, the first one needs some research:
- Write the buffer to
/dev/null
and set upBufWritePre
autocmds to update the secure note in 1Password (important: would need to validate whether writing to/dev/null
compromises the security of the note in some way) - Just use a separate command to update the secure note in 1Password, like
:OpWrite
or :OpSaveNote` or something like that
This could actually be a really awesome way to use 1Password secure notes. If I can get it working well enough/seamlessly enough it might even replace Notion for me.
After a little research, first option cannot be guaranteed to be secure. It is possible to replace /dev/null
with something else if you have administrative privileges. While this is extremely unlikely, we shouldn't even open the possibility.
The buffer must be buftype=nofile
and use a separate, dedicated command for updating in 1Password.
@tsyroid thoughts on:
:OpWrite
(possibly with:OpW
as a shorthand?):OpSave
:OpSync
(though maybe this should also reload changes from 1Password into the buffer?)- Something else
Should also wait for #26 so we can update the notes in 1Password asynchronously.
Another idea is we could split note titles on >
to make a simulated hierarchy/directory structure and make a 1Password secure notes sidebar.