Skip to content

User Commands

The plugin registers user commands that you can run from NeoVim’s command line (:ZkCommand). All commands support tab completion for flags and values.

Create a new zettel. Defaults to untethered if no category is given.

" Create an untethered note (default)
:ZkNote
" Create an untethered note (explicit)
:ZkNote --category untethered
" Create a tethered note with a project
:ZkNote --category tethered --project my-project

Flags:

FlagValuesDescription
--categoryuntethered, tetheredNote category (default: untethered)
--projectany stringProject name (auto-detected from git if omitted)

Create a note from a template. Opens a picker if no template name is given.

" Open template picker
:ZkTemplate
" Create meeting notes
:ZkTemplate meeting
" Create a feature spec for a project
:ZkTemplate feature --project my-project

Available templates: meeting, book-review, snippet, project-idea, user-story, feature, daily


Search zettels. Opens a picker if available, otherwise prints results. Use the bang (!) variant for live search that updates as you type.

" Search for a term
:ZkSearch authentication
" Live search (updates as you type)
:ZkSearch!
" Live search with an initial query
:ZkSearch! auth
" Filter by category and project
:ZkSearch --category tethered --project my-project
" Filter by type and status
:ZkSearch --type todo --status open
" Filter by priority and due date
:ZkSearch --priority high --due-before 2026-03-01
" Filter by tag
:ZkSearch --tag security
" Combine a query with filters
:ZkSearch auth --category tethered --tag security

Flags:

FlagValuesDescription
--categoryuntethered, tetheredFilter by category
--projectany stringFilter by project
--typenote, todo, daily-note, issueFilter by note type
--statusopen, in_progress, closedFilter by status
--priorityhigh, medium, lowFilter by priority
--due-beforeYYYY-MM-DDDue before date
--due-afterYYYY-MM-DDDue after date
--tagany stringFilter by tag (can repeat)

Picker keymaps (when available):

KeyAction
<CR>Open note
<C-p>Preview in floating window
<C-l>Insert [[id]] link at cursor
<C-S-l>Insert [[id|title]] link at cursor

Generate an ASCII tree visualization of note relationships. Opens in a vertical split.

" Default graph (limit 10 nodes)
:ZkGraph
" Limit number of nodes
:ZkGraph --limit 20
:ZkGraph 20
" Start from a specific note
:ZkGraph --start 20260213143000-550e8400-e29b-41d4-a716-446655440000
" Set traversal depth
:ZkGraph --depth 3
" Combine options
:ZkGraph --start 20260213143000-550e8400-e29b-41d4-a716-446655440000 --depth 3 --limit 50

Flags:

FlagValuesDescription
--limitnumberMaximum nodes to display (default: 10)
--startzettel IDStart node for the graph
--depthnumberTraversal depth

Open or create a daily note. Daily notes are idempotent — running it twice on the same day opens the same file.

" Today's daily note
:ZkDaily
" Yesterday's note (for morning review)
:ZkDaily yesterday
" Specific date
:ZkDaily 2026-02-10

Browse daily notes in a picker. Use the bang variant to show only this week.

" Browse all daily notes
:ZkDailyList
" This week only
:ZkDailyList!

Create a new todo. The title is everything that isn’t a flag.

" Simple todo
:ZkTodo Buy a notebook for handwritten zettel drafts
" With due date and priority
:ZkTodo Review meeting notes --due 2026-02-21 --priority high
" With project
:ZkTodo Fix login bug --project my-project --priority medium

Flags:

FlagValuesDescription
--dueYYYY-MM-DDDue date
--priorityhigh, medium, lowPriority level
--projectany stringProject name

Generate a markdown summary of todos and open it in a split.

" All open todos
:ZkTodoList
" Due today
:ZkTodoList today
" Due this week
:ZkTodoList week
" Project-specific list
:ZkTodoList my-project

Index zettels for full-text search. Indexes the current directory by default.

" Index current directory
:ZkIndex
" Index specific path
:ZkIndex ~/zk_vault/

Clear the tag cache and reload tags from the index.

:ZkRefreshTags

CommandDescription
:ZkNoteCreate new zettel
:ZkTemplate [name]Create from template
:ZkSearch[!] [query]Search zettels (! for live search)
:ZkGraphGraph visualization
:ZkDaily [date]Open daily note
:ZkDailyList[!]Browse daily notes (! for this week)
:ZkTodo [title]Create a todo
:ZkTodoList [filter]Generate todo list markdown
:ZkIndex [path]Index zettels
:ZkRefreshTagsRefresh tag cache