aboutsummaryrefslogtreecommitdiff
path: root/modules/music-config.el
Commit message (Collapse)AuthorAgeFilesLines
* feat(window): remember a side window's size across togglesCraig Jennings9 days1-2/+18
| | | | | | | | | | The F10 music playlist opened at a fixed fraction every time, so any manual resize was lost the moment it was toggled closed. Now the toggle captures the window's size on close and reopens at that height, for the rest of the session. The mechanism is generic, not music-specific. cj/window-size-fraction (geometry-lib) is the pure kernel: a clamped window/frame ratio. cj/side-window-capture-size and cj/side-window-display (toggle-lib) wrap it for any display-buffer-in-side-window consumer — height for top/bottom, width for left/right — storing the remembered fraction in a caller-supplied state var. It mirrors the direction-split toggle pattern the vterm dispatchers already use, but for atomic side windows that can't be split. music-config wires F10 to it: cj/music-playlist-window-height is the default, cj/--music-playlist-height holds the remembered value (in-memory, resets each session). 12 new tests across the two libs, Normal/Boundary/Error each covered.
* refactor(load-graph): route C-; registration through the keymap APICraig Jennings12 days1-1/+1
| | | | | | Migrated all 31 cj/custom-keymap registration sites across 24 modules from direct (keymap-set cj/custom-keymap ...) calls to cj/register-prefix-map and cj/register-command. Consumers no longer reference cj/custom-keymap directly, so keybindings.el is the sole owner of the C-; prefix and modules reach it only through the API (each already requires keybindings from Phase 2). Behavior-preserving: I dumped every C-; binding before and after the migration and they're identical: 279 bindings, each resolving to the same command. The which-key label blocks are untouched, since they use string key descriptions and never assumed the keymap existed. I byte-compiled all 24 files (no new free-variable warnings, because the cj/custom-keymap references are gone), and make test, validate-modules, and an init load all pass.
* docs(load-graph): classify remaining domain and optional modulesload-graph-classify-endCraig Jennings12 days1-0/+10
| | | | | | Final classification batch: the last 19 modules — linear-config, local-repository, lorem-optimum, mail-config, markdown-config, music-config, pdf-config, quick-video-capture, reconcile-open-repos, restclient-config, slack-config, system-commands, telega-config, tramp-config, transcription-config, video-audio-recording, vterm-config, weather-config, wrap-up. I annotated each header, added a Batch 9 table to the inventory, and extended the validation allowlist. 101 of 102 modules are now classified; only elfeed-config remains, deferred on its test fix. Two more hidden dependencies turned up. video-audio-recording uses the boundp shim for its C-; r binding, and mail-config registers C-; e directly without requiring keybindings, so it errors standalone rather than degrading. Both recorded for Phase 2.
* chore(modules): pass validate-modules in batch by adding requiresCraig Jennings2026-05-071-0/+1
| | | | | | | | `make validate-modules` had 19 module-load failures, all the same shape: a module references a symbol or feature owned by another module without saying so. Production was fine because init.el orders requires correctly. The batch target loads each module in isolation, though, and surfaces the gap. I added explicit `(require 'keybindings)` or `(require 'user-constants)` to each affected module. The requires are idempotent at runtime, so production load order is unchanged. For three optional packages (elpa-mirror, mu4e, org-contacts), I switched to `(require 'X nil t)` so the modules load cleanly when those packages aren't installed. The activation calls become no-ops in that case. `make validate-modules` now reports 0 failures.
* feat(music): add random-aware next/previous; refactor music + calendar-syncCraig Jennings2026-04-031-15/+67
| | | | | | | | | | Music: random mode now respected by next/previous keys. Previous navigates a 50-track play history ring buffer. Fixed playlist replacement bug. 24 new tests. Calendar-sync: consolidated duplicate parse functions, extracted timezone localization helper, unified expand-daily/monthly/yearly into parameterized function, removed dead code. 33 new characterization tests. -90 lines.
* feat(music): add test coverage for 7 functions, refactor with extracted helpersCraig Jennings2026-04-011-36/+45
| | | | | | | | | | | | Add 47 new unit tests across 7 test files covering playlist-modified-p, assert-valid-playlist-file, playlist-tracks, create-radio-station, ensure-playlist-buffer, after-playlist-clear, and header-text. Extract three helpers to reduce duplication: assert-m3u-files-exist (dedupes 2 identical guards), sync-playlist-file (dedupes 3 state-sync patterns), and select-m3u-file (reusable M3U selection with cancel). Simplify append-track-to-playlist nesting from 6 to 4 levels. Delete unused cj/music-keymap-prefix variable.
* fix(music): place point on first track after playlist load/reloadCraig Jennings2026-03-101-2/+4
|
* fix(music): force case-insensitive search when adding songsCraig Jennings2026-02-211-0/+1
| | | | | Bind orderless-smart-case to nil in cj/music-fuzzy-select-and-add so typing uppercase characters doesn't switch to case-sensitive matching.
* feat(music): add playlist UI with header overlay, track styling, and testsCraig Jennings2026-02-151-2/+182
| | | | | | | | | | | Replace raw file paths with clean track descriptions (Artist - Title [M:SS]), add multi-line header overlay showing playlist info, now-playing, mode indicators with gold/muted toggle states, and keybinding hints. Style non-playing tracks in Dupre steel, playing track in Dupre gold. Playlist window now opens from the bottom at 50% height with subtle background highlight on focus. Unit tests for format-duration (13 tests) and track-description (16 tests).
* docs(music): add ncmpcpp keybinding comparison table to commentaryCraig Jennings2026-02-151-0/+65
| | | | | | Document playlist-mode keybindings with ncmpcpp default alignment status (83% match). Note intentional divergences (SPC/p swap, x=consume vs crossfade) and EMMS-only features.
* feat(music): align EMMS keybindings with ncmpcpp, add consume modeCraig Jennings2026-02-151-12/+60
| | | | | | | | | | Reconcile playlist-mode bindings with ncmpcpp defaults: add ncmpcpp- compatible aliases (>/<, +, S-up/S-down, c), new toggles (r repeat, t repeat-track, z random, x consume), info keys (i, o), and relocate radio (r→R), reload (R→g), shuffle (x→Z). Add consume mode that removes tracks from playlist after playback via emms-player-finished- hook. Fix buffer-local bug where emms-playlist-selected-marker was checked outside with-current-buffer. 13 ERT tests.
* feat(music): add dirvish keybinding for EMMS playlistCraig Jennings2026-02-011-1/+3
| | | | Bind + to cj/music-add-dired-selection in dirvish-mode-map.
* feat(dwim-shell): fix M-D menu binding and enhance audio extractionCraig Jennings2025-11-241-3/+1
| | | | | | | | | | | | | | | | | | | | - Fix dwim-shell-commands-menu keybinding in dirvish/dired - Remove :after (dired dirvish) which prevented package loading - Add :demand t to load package immediately at startup - Move keybindings inside :config block after menu function definition - M-D now works immediately in dirvish without manual trigger - Enhance extract-audio-from-video function - Fix :extensions parameter (was regex string, now proper list) - Change from copy to AAC re-encoding for codec compatibility - Add interactive bitrate selection (64k/96k/128k/192k) - Fixes Opus codec compatibility issues with M4A containers - Remove conflicting keybindings - Remove music-config p binding in dirvish (was overriding path copy) - Clean up extraneous requires/hooks from troubleshooting - Add TODO for dwim-shell-command status dashboard [#D priority]
* feat(music): Switch EMMS from MPD to MPV backendCraig Jennings2025-11-151-27/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Major improvements to music player configuration: Backend Changes: - Switch from emms-player-mpd to emms-player-mpv - Remove MPD daemon dependency (no service management required) - Configure MPV with --quiet, --no-video, --audio-display flags - Support both local files and streaming URLs (http/https/mms) Keybinding Enhancements: - Add C-; m n → next track - Add C-; m p → previous track - Add C-; m g → go to playlist - In playlist: n/P for next/prev, f/b for seek forward/backward - Update which-key descriptions Code Quality: - Use music-dir constant from user-constants.el (not hardcoded path) - Add (require 'user-constants) for proper dependency - Update commentary to reflect MPV backend Test Fixes: - Fix 8 failing append-track tests - Update test mock data to use cj/music-root for portability - All 104 music-config tests now passing Benefits: - No daemon to start/stop/manage - Simpler architecture (one process vs MPD+EMMS) - Streaming radio URLs work out of the box - Better path consistency across codebase
* fix: Write relative paths to M3U playlists instead of absoluteCraig Jennings2025-11-121-14/+18
| | | | | | | | Changed cj/music--append-track-to-m3u-file to convert absolute paths to relative paths from cj/music-root before writing to M3U files. This fixes playlist loading in Mopidy, which expects relative paths in M3U files based on the configured base_dir.
* chore: Update todo.org with new inbox items and music-config improvementsCraig Jennings2025-11-011-6/+63
| | | | | | | | | | | | todo.org updates: - Added 2 new inbox items about printing keybindings - Reordered Method 1 tasks by priority - Removed blank lines (linter formatting) music-config.el improvements: - Added validation checks to cj/music--valid-file-p and cj/music--valid-directory-p - Fixed regex escaping in cj/music--m3u-file-tracks - Added new cj/music--append-track-to-m3u-file function for testing
* feat:which-key: Add descriptive labels for custom keymapsCraig Jennings2025-10-271-1/+10
| | | | | | | | | | | | Enhance which-key integration by providing detailed descriptions for new key bindings across multiple modules. This improves the usability of custom keymaps by clarifying the purpose of each keybinding, making it easier for users to navigate and understand different menus and options available within the configuration. This update ensures that all custom keymaps now display a descriptive label in the which-key popup to explain their functionality, aiding users in identifying keymap purposes promptly.
* refactor:keymaps: Replace define-prefix-command with defvar-keymapCraig Jennings2025-10-251-14/+17
| | | | | | | | | | Refactor the keymap definitions across multiple modules by replacing `define-prefix-command` with `defvar-keymap`. This simplifies the keymap setup and integrates better with the `which-key` package for enhanced documentation and usability. Updated modules include custom-ordering, custom-text-enclose, custom-whitespace, mail-config, music-config, org-drill-config, test-runner, and vc-config.
* chore: music: remove eradio-config and update music-configCraig Jennings2025-10-251-75/+54
| | | | | | | | | Deleted eradio-config.el file as it is no longer needed. Refactored music-config.el to improve readability and maintainability by removing unused autoload directives, unnecessary eval-when-compile blocks, adjusting indentation, and enhancing the setup function for EMMS. Additionally, removed duplicate code and ensured playlist handling is more robust.
* refactor: unify and simplify key binding setupsCraig Jennings2025-10-231-12/+29
| | | | | | | | Optimized key binding configurations across modules for consistency and reduced redundancy. Improved conditional requiring to handle errors gracefully in `music-config.el`, ensuring robustness across different machine environments. Eliminated comments clutter and adjusted function definitions to adhere to revised standards.
* fix:music: issue with not setting EMMS Playlist name and spacesCraig Jennings2025-10-191-23/+21
|
* fix: music-config: rogue commas introduced by "convenience" functionCraig Jennings2025-10-181-1/+1
|
* refactor: music-config: streamline EMMS integration + error handlingCraig Jennings2025-10-181-495/+363
| | | | | | | | | Simplified EMMS configuration: - restructured helper functions - standardized error handling - removed redundant wrappers - ensured buffer state synchronization - improved Dired/Dirvish integration for playlist management
* fix: dirvish: add key to dirvish keymap only after dirvish is loadedCraig Jennings2025-10-161-1/+1
|
* fix: only use mpd to play music; fix space in playlist buffernameCraig Jennings2025-10-151-2/+14
|
* feat: complete music/dired integration with dired add to playlistCraig Jennings2025-10-121-25/+26
|
* changing repositoriesCraig Jennings2025-10-121-0/+597