nncli

NextCloud Notes Command Line Interface
git clone git://git.danielmoch.com/nncli.git
Log | Files | Refs | LICENSE

commit cb5ef04d3fa8a45054a16d517e3525071045848e
parent d49e5c705debe0a1e088112585e1a75378a4f395
Author: Daniel Moch <daniel@danielmoch.com>
Date:   Sat, 18 Dec 2021 07:29:27 -0500

cli: Modify edit to accept from_stdin flag

Diffstat:
Mnncli/cli.py | 2+-
Mnncli/nncli.py | 2+-
2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/nncli/cli.py b/nncli/cli.py @@ -177,7 +177,7 @@ def delete(nncli, key): ) @click.argument('from_stdin', metavar='[-]', type=STDIN_FLAG) @click.pass_obj -def edit(nncli, key): +def edit(nncli, key, from_stdin): """ Edit an existing note. If - is specified, the note contents are read from stdin, otherwise the editor will open. diff --git a/nncli/nncli.py b/nncli/nncli.py @@ -170,7 +170,7 @@ def cli_export_notes(self, regex, search_string): notes_data = [n.note for n in note_list] print(json.dumps(notes_data, indent=2)) - def cli_note_edit(self, key): + def cli_note_edit(self, from_stdin, key): """Edit a note from the command line""" note = self.ndb.get_note(key) if not note: