MCPcopy Create free account
hub / github.com/ZenNotes/zennotes / cmdAppend

Function cmdAppend

apps/desktop/src/cli/commands/notes.ts:133–141  ·  view source on GitHub ↗
(vault: string, args: ParsedArgs)

Source from the content-addressed store, hash-verified

131}
132
133export async function cmdAppend(vault: string, args: ParsedArgs): Promise<void> {
134 const rel = requirePath(args)
135 const body = await resolveBody(args)
136 if (body == null || body.trim() === '') {
137 throw new Error('zn append requires --body, a positional body, or piped stdin.')
138 }
139 const meta = await appendToNote(vault, rel, body)
140 emitWritten(meta, args)
141}
142
143export async function cmdPrepend(vault: string, args: ParsedArgs): Promise<void> {
144 const rel = requirePath(args)

Callers

nothing calls this directly

Calls 4

requirePathFunction · 0.85
resolveBodyFunction · 0.85
emitWrittenFunction · 0.85
appendToNoteFunction · 0.50

Tested by

no test coverage detected