From 8c04dc2f5fee2c19489887433632347d3be74582 Mon Sep 17 00:00:00 2001 From: Craig Jennings Date: Mon, 9 Feb 2026 09:34:53 -0600 Subject: feat(dotfiles): manage calibre via directory symlink, add ncmpcpp bindings Calibre does atomic writes that break individual stow symlinks. Exclude calibre from stow and use a directory symlink instead. Add ncmpcpp keybindings for space/pause, arrow seek, playlist add, visualization. --- dotfiles/common/.config/calibre/.gitignore | 5 + .../common/.config/calibre/dynamic.pickle.json | 21 ++++ dotfiles/common/.config/calibre/global.py.json | 82 ++++++++++++++ dotfiles/common/.config/calibre/gui.json | 16 +-- .../.config/calibre/plugins/Kobo Utilities.json | 122 +++++++++++++++++++++ dotfiles/common/.config/ncmpcpp/bindings | 15 +++ 6 files changed, 253 insertions(+), 8 deletions(-) create mode 100644 dotfiles/common/.config/calibre/.gitignore create mode 100644 dotfiles/common/.config/calibre/dynamic.pickle.json create mode 100644 dotfiles/common/.config/calibre/global.py.json create mode 100644 dotfiles/common/.config/calibre/plugins/Kobo Utilities.json (limited to 'dotfiles/common/.config') diff --git a/dotfiles/common/.config/calibre/.gitignore b/dotfiles/common/.config/calibre/.gitignore new file mode 100644 index 0000000..f80339c --- /dev/null +++ b/dotfiles/common/.config/calibre/.gitignore @@ -0,0 +1,5 @@ +# Calibre runtime files (not worth tracking) +caches/ +fonts/scanner_cache.json +icons-dark.rcc +viewer/annots/ diff --git a/dotfiles/common/.config/calibre/dynamic.pickle.json b/dotfiles/common/.config/calibre/dynamic.pickle.json new file mode 100644 index 0000000..fb42097 --- /dev/null +++ b/dotfiles/common/.config/calibre/dynamic.pickle.json @@ -0,0 +1,21 @@ +{ + "sort_history": [ + [ + "timestamp", + false + ], + [ + "ondevice", + false + ], + [ + "title", + true + ], + [ + "timestamp", + false + ] + ], + "welcome_wizard_was_run": true +} \ No newline at end of file diff --git a/dotfiles/common/.config/calibre/global.py.json b/dotfiles/common/.config/calibre/global.py.json new file mode 100644 index 0000000..43f47a0 --- /dev/null +++ b/dotfiles/common/.config/calibre/global.py.json @@ -0,0 +1,82 @@ +{ + "add_formats_to_existing": false, + "case_sensitive": false, + "check_for_dupes_on_ctl": false, + "database_path": "/home/cjennings/library1.db", + "filename_pattern": "(?P.+) - (?P<author>[^_]+)", + "input_format_order": [ + "EPUB", + "PDF", + "AZW3", + "MOBI", + "LIT", + "PRC", + "FB2", + "HTML", + "HTM", + "XHTM", + "SHTML", + "XHTML", + "ZIP", + "DOCX", + "ODT", + "RTF", + "TXT", + "CB7", + "SHTM", + "SNB", + "PMLZ", + "TCR", + "FBZ", + "DJVU", + "DOCM", + "LRF", + "TXTZ", + "KEPUB", + "POBI", + "PDB", + "CHM", + "CBR", + "HTMLZ", + "RB", + "MD", + "CBC", + "MARKDOWN", + "TEXT", + "AZW", + "UPDB", + "RECIPE", + "PML", + "DOWNLOADED_RECIPE", + "TEXTILE", + "RAR", + "CBZ", + "OPF", + "AZW4", + "DJV" + ], + "installation_uuid": "4c998702-215a-4787-a019-abdee4cdf53c", + "isbndb_com_key": "", + "language": "en", + "library_path": "/home/cjennings/sync/books", + "limit_search_columns": false, + "limit_search_columns_to": [ + "title", + "authors", + "tags", + "publisher" + ], + "manage_device_metadata": "manual", + "mark_new_books": true, + "migrated": false, + "network_timeout": 5, + "new_book_tags": [], + "numeric_collation": false, + "output_format": "epub", + "read_file_metadata": true, + "saved_searches": {}, + "swap_author_names": false, + "use_primary_find_in_search": true, + "user_categories": {}, + "worker_process_priority": "normal" +} \ No newline at end of file diff --git a/dotfiles/common/.config/calibre/gui.json b/dotfiles/common/.config/calibre/gui.json index 853dbd8..b1e1c40 100644 --- a/dotfiles/common/.config/calibre/gui.json +++ b/dotfiles/common/.config/calibre/gui.json @@ -212,28 +212,28 @@ }, "geometry-of-calibre_main_window_geometry": { "frame_geometry": { - "height": 1306, - "width": 1828, + "height": 1314, + "width": 3374, "x": 0, "y": 0 }, "full_screened": false, "geometry": { - "height": 1306, - "width": 1828, + "height": 1314, + "width": 3374, "x": 0, "y": 0 }, "maximized": true, "normal_geometry": { - "height": 1306, + "height": 1314, "width": 1828, "x": 0, "y": 0 }, "qt": { "__class__": "bytearray", - "__value__": "AdnQywADAAAAAAAAAAAAAAAAByMAAAUZAAAAAAAAAAAAAAcjAAAFGQAAAAACAAAADXAAAAAAAAAAAAAAByMAAAUZ" + "__value__": "AdnQywADAAAAAAAAAAAAAAAADS0AAAUhAAAAAAAAAAAAAAcjAAAFIQAAAAACAAAADXAAAAAAAAAAAAAADS0AAAUh" }, "screen": { "depth": 32, @@ -247,7 +247,7 @@ "index_in_screens_list": 0, "manufacturer": "Dell Inc.", "model": "DELL U3419W", - "name": "HDMI-A-1", + "name": "DP-4", "serial": "", "size_in_logical_pixels": { "height": 1440, @@ -468,7 +468,7 @@ "grid view visible": false, "library_usage_stats": { "/home/cjennings/archive/books": 10, - "/home/cjennings/sync/books": 10 + "/home/cjennings/sync/books": 12 }, "light_palette_name": "", "light_palettes": { diff --git a/dotfiles/common/.config/calibre/plugins/Kobo Utilities.json b/dotfiles/common/.config/calibre/plugins/Kobo Utilities.json new file mode 100644 index 0000000..4d9121a --- /dev/null +++ b/dotfiles/common/.config/calibre/plugins/Kobo Utilities.json @@ -0,0 +1,122 @@ +{ + "BookmarkOptions": { + "backgroundJob": false, + "clearIfUnread": false, + "doNotStoreIfReopened": false, + "rating": true, + "readingStatus": true, + "setDateToNow": true, + "storeBookmarks": true, + "storeIfMoreRecent": false + }, + "Devices": { + "N4181C1037466": { + "active": true, + "backupOptionsStore": { + "backupCopiesToKeepSpin": 10, + "backupDestDirectory": "/home/cjennings/documents/kobo", + "backupEachCOnnection": true, + "backupZipDatabase": true, + "doDailyBackp": false + }, + "location_code": "main", + "name": "Kobo Libra 2", + "serial_no": "N4181C1037466", + "type": "Kobo Libra 2", + "updateOptionsStore": { + "doEarlyFirmwareUpdate": false, + "doFirmwareUpdateCheck": true, + "firmwareUpdateCheckLastTime": 0 + }, + "uuid": "8de75c8a-f9b6-405c-86a3-515afd1e71fa" + } + }, + "MetadataOptions": { + "author": false, + "authourSort": false, + "description": false, + "descriptionTemplate": "", + "descriptionUseTemplate": false, + "isbn": false, + "language": false, + "published_date": false, + "publisher": false, + "rating": false, + "readingStatus": -1, + "reading_direction": "Default", + "resetPosition": false, + "series": false, + "setRreadingStatus": false, + "set_reading_direction": false, + "set_sync_date": false, + "subtitle": false, + "subtitleTemplate": "", + "sync_date_library_date": "timestamp", + "title": false, + "titleSort": false, + "update_KoboEpubs": false, + "usePlugboard": false + }, + "ReadingOptions": { + "doNotUpdateIfSet": false, + "lockMargins": false, + "readingAlignment": "Off", + "readingFontFamily": "Georgia", + "readingFontSize": 22, + "readingLeftMargin": 3, + "readingLineHeight": 1.3, + "readingRightMargin": 3, + "updateConfigFile": false + }, + "_version": 2, + "backupAnnotations": { + "dest_directory": "" + }, + "backupOptionsStore": { + "backupCopiesToKeepSpin": 5, + "backupDestDirectory": "", + "backupEachCOnnection": false, + "backupZipDatabase": true, + "doDailyBackp": false + }, + "cleanImagesDir": { + "delete_extra_covers": false + }, + "commonOptionsStore": { + "buttonActionDevice": "", + "buttonActionLibrary": "", + "individualDeviceOptions": true + }, + "coverUpload": { + "blackandwhite": false, + "dithered_covers": false, + "keep_cover_aspect": false, + "kepub_covers": false, + "letterbox": false, + "letterbox_color": "#000000", + "png_covers": false + }, + "fixDuplicatesOptionsStore": { + "keepNewestShelf": true, + "purgeShelves": false + }, + "getShelvesOptionStore": { + "allBooks": true, + "replaceShelves": true + }, + "removeAnnotations": { + "removeAnnotAction": 0 + }, + "removeCovers": { + "kepub_covers": false, + "remove_fullsize_covers": false + }, + "setRelatedBooksOptionsStore": { + "relatedBooksType": 0 + }, + "updateOptionsStore": { + "doEarlyFirmwareUpdate": false, + "doFirmwareUpdateCheck": false, + "firmwareUpdateCheckLastTime": 1656213583 + } +} \ No newline at end of file diff --git a/dotfiles/common/.config/ncmpcpp/bindings b/dotfiles/common/.config/ncmpcpp/bindings index a7ca6c0..25021f1 100644 --- a/dotfiles/common/.config/ncmpcpp/bindings +++ b/dotfiles/common/.config/ncmpcpp/bindings @@ -219,6 +219,9 @@ #def_key "space" # toggle_visualization_type # +def_key "space" + pause + #def_key "delete" # delete_playlist_items # @@ -237,6 +240,9 @@ #def_key "right" # volume_up # +def_key "right" + seek_forward +# #def_key "+" # volume_up # @@ -249,6 +255,9 @@ #def_key "left" # volume_down # +def_key "left" + seek_backward +# #def_key "-" # volume_down # @@ -309,6 +318,9 @@ def_key "=" #def_key "p" # pause # +def_key "p" + add_item_to_playlist + #def_key ">" # next # @@ -453,6 +465,9 @@ def_key "l" #def_key "v" # reverse_selection # +def_key "v" + toggle_visualization_type + #def_key "V" # remove_selection # -- cgit v1.2.3