Minimal bridge between editor buffers, the system clipboard, and the duras CLI.
Requires duras 1.1.0 or later.
Two files. Same commands.
| File | Editor |
|---|---|
duras_bridge.vim |
Vim (incl. a-Shell) |
duras_bridge.lua |
Neovim |
No dependencies. No plugin manager required.
Neovim — lazy.nvim
{ url = 'https://github.com/sduras/duras_bridge' }Vim — vim-plug
Plug 'https://github.com/sduras/duras_bridge'Vim — pathogen
git clone https://github.com/sduras/duras_bridge ~/.vim/bundle/duras_bridgeThe plugin files live in plugin/. Any manager that adds the repo root to
the runtimepath will load the correct file automatically — Vim sources
duras_bridge.vim, Neovim sources duras_bridge.lua. A shared guard
(g:loaded_duras_bridge) prevents both from loading on Neovim.
After install, run :helptags ALL (or let the plugin manager do it) to
enable :help duras_bridge.
Clone once, point the editor at it:
git clone https://github.com/sduras/duras_bridge ~/src/duras_bridgeVim — add to .vimrc:
set runtimepath+=~/src/duras_bridgeNeovim — add to init.lua:
vim.opt.runtimepath:append(vim.fn.expand('~/src/duras_bridge'))To update: git pull in the cloned directory. No file copying needed.
If you prefer not to clone the repository, copy or symlink the plugin file directly:
# Vim
cp plugin/duras_bridge.vim ~/.vim/plugin/
# Neovim
cp plugin/duras_bridge.lua ~/.config/nvim/plugin/Verify it loaded:
:scriptnames:echo system('duras --version')Clipboard (a-Shell / macOS):
:echo system('pbpaste')Clipboard (Linux):
:echo system('xclip -selection clipboard -o')If empty or error: fallback to getreg('+').
:DOpen " today
:DOpen 2026-04-20
:DOpen -1 " offset:DAppend " buffer or selection
:DAppend text
:DAppend - " clipboardText is normalized by duras before storage: trailing whitespace stripped per line, consecutive blank lines collapsed to one, tabs converted to spaces. This applies to all three input modes.
:DSearch keyword
:DSearch project meetingNavigation:
<CR>— open:q— close
:DClipYank " buffer → clipboard
:DClipPaste " clipboard → below cursor
:DCopyPath " note path → clipboard:DStats
:DPath
:DTags
:DTags projectPass tag names without #.
| Key | Action |
|---|---|
<leader>do |
:DOpen |
<leader>da |
:DAppend |
<leader>ds |
:DSearch |
<leader>dp |
:DPath |
Visual mode: <leader>da appends selection.
Disable by commenting mappings at file end:
- Vim:
nnoremap/vnoremap - Neovim:
vim.keymap.set
No no_mappings guard.
Priority:
pbcopy/pbpaste(iOS, macOS)xclip/xsel(X11)getreg('+')/setreg('+')
All system calls checked by exit status.
- Clipboard tools may be absent; fallback used
system()is synchronous; large note sets may introduce latency
- Encrypted notes (
.dn.gpg) unsupported — useduras -cin shell :DAppendalways appends to today — useduras append -d DATE textin shell for past dates:DSearchhas no-iflag — useduras search -ifrom shell
- No background processes
- No state beyond buffer/clipboard
- No deviation from
durasCLI behavior