nncli

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

commit b44752490faf1a5767c22a487f9ebc8b42c5967e
parent d843714290be3cdb50ba1d5c80da06971051bb09
Author: Shawn Axsom <shawn.axsom@rooksecurity.com>
Date:   Sat,  4 Apr 2015 15:06:34 -0400

Add pbcopy support

Diffstat:
Msimplenote_cli/clipboard.py | 2++
Msimplenote_cli/config.py | 2+-
2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/simplenote_cli/clipboard.py b/simplenote_cli/clipboard.py @@ -9,6 +9,8 @@ def __init__(self): def get_copy_command(self): if (spawn.find_executable('xsel')): return 'echo "%s" | xsel -ib' + if (spawn.find_executable('pbcopy')): + return 'echo "%s" | pbcopy' return None def copy(self, text): diff --git a/simplenote_cli/config.py b/simplenote_cli/config.py @@ -190,7 +190,7 @@ def __init__(self): self.keybinds['note_pin'] = [ cp.get(cfg_sec, 'kb_note_pin'), [ 'titles', 'notes' ], 'Pin note' ] self.keybinds['note_markdown'] = [ cp.get(cfg_sec, 'kb_note_markdown'), [ 'titles', 'notes' ], 'Flag note as markdown' ] self.keybinds['note_tags'] = [ cp.get(cfg_sec, 'kb_note_tags'), [ 'titles', 'notes' ], 'Edit note tags' ] - self.keybinds['copy_note_text'] = [ cp.get(cfg_sec, 'kb_copy_note_text'), [ 'notes' ], 'Copy current line with xsel' ] + self.keybinds['copy_note_text'] = [ cp.get(cfg_sec, 'kb_copy_note_text'), [ 'notes' ], 'Copy line (xsel/pbcopy)' ] self.colors = collections.OrderedDict() self.colors['default_fg'] = [ cp.get(cfg_sec, 'clr_default_fg'), 'Default fg' ]