From c6f89b8f3377a6d6197616e402a9c5341709c540 Mon Sep 17 00:00:00 2001 From: Mecaneer23 <74385377+Mecaneer23@users.noreply.github.com> Date: Thu, 20 Jun 2024 16:35:23 -0500 Subject: [PATCH] fix: copy operation on multiple lines --- src/clipboard.py | 4 +++- todo.txt | 3 +-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/clipboard.py b/src/clipboard.py index 155a3d0..1be0a65 100644 --- a/src/clipboard.py +++ b/src/clipboard.py @@ -41,7 +41,9 @@ def copy_todo( "Copy dependency not available: try running `pip install pyperclip`", ) return - copy(todos[int(selected)].get_display_text()) # pyright: ignore + copy( # pyright: ignore[reportPossiblyUnboundVariable] + "\n".join([todos[pos].get_display_text() for pos in selected.get()]) + ) def _todo_from_clipboard( diff --git a/todo.txt b/todo.txt index 74f4fd0..2e941cd 100644 --- a/todo.txt +++ b/todo.txt @@ -16,5 +16,4 @@ - in main window - fix: acurses preserve terminal from prior to app instantiation - fix: overflow in get_todo for lines with length > 2*width -- fix: copy operation on multiple lines should work for clipboard - - maybe migrate copied_todo to list of todos and add multiple line paste operation from in app copy? \ No newline at end of file +- feat: migrate copied_todo to list of todos and add multiple line paste operation from in app copy \ No newline at end of file