feat(cast): headless CLI flags (-stop, -cast-list, -cast-to, -cast-stop) - #78
Open
susamn wants to merge 1 commit into
Open
feat(cast): headless CLI flags (-stop, -cast-list, -cast-to, -cast-stop)#78susamn wants to merge 1 commit into
susamn wants to merge 1 commit into
Conversation
susamn
force-pushed
the
feature/cast-ui
branch
from
August 28, 2026 02:54
7f382bc to
aea1cad
Compare
susamn
force-pushed
the
feature/cast-cli-flags
branch
from
August 28, 2026 02:54
3beef62 to
5b71664
Compare
susamn
force-pushed
the
feature/cast-ui
branch
from
August 28, 2026 03:06
aea1cad to
e47d658
Compare
susamn
force-pushed
the
feature/cast-cli-flags
branch
from
August 28, 2026 03:06
5b71664 to
c9eaaa7
Compare
Adds one-shot headless actions to cmd/mpdtui, in the same style as -i/-p:
- -stop stop MPD playback and exit
- -cast-list list discovered cast targets and exit
- -cast-to NAME start casting to the named/id'd target and exit
- -cast-stop tear down the active cast (stop device, restore outputs)
and exit -- works with no TUI running, via the persisted
session file or a discovery fallback
These delegate to the existing cast.List / cast.Start / cast.Stop
entrypoints. They are mutually exclusive with each other and with the UI
modes, checked separately so the existing exclusivity message (and its
tests) is untouched. The cast Manager is built once and shared with the
full UI; metaDB is not opened for these actions.
Also documents the cast config keys in the first-run config template.
Tests: cli_internal_test.go (List/Start/Stop against fake providers),
plus three new main_test.go flag-validation cases.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JBJdG8Qenand5i16WT6BHG
susamn
force-pushed
the
feature/cast-cli-flags
branch
from
August 28, 2026 03:47
c9eaaa7 to
cccad70
Compare
susamn
force-pushed
the
feature/cast-ui
branch
from
August 28, 2026 03:47
e47d658 to
aaa408f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #77.
One-shot headless actions in
cmd/mpdtui, same style as-i/-p:-stop-cast-list-cast-to NAME-cast-stopDelegate to the existing
cast.List/Start/Stop. Mutually exclusive with each other and the UI modes, checked separately so the existing exclusivity message + its tests stay untouched. Manager built once, shared with the full UI; metaDB not opened for these.Also documents the cast config keys in the first-run config template.
Tests:
cli_internal_test.go+ 3 newmain_test.gocases. No new deps.After this: only README + the HA/DLNA providers remain.