feat(voice): support CC_VOICE env var for one-off voice override#71
Open
mthlvt wants to merge 1 commit intopchalasani:mainfrom
Open
feat(voice): support CC_VOICE env var for one-off voice override#71mthlvt wants to merge 1 commit intopchalasani:mainfrom
mthlvt wants to merge 1 commit intopchalasani:mainfrom
Conversation
Adds a CC_VOICE environment variable that overrides the voice in ~/.claude/voice.local.md without requiring an edit to the config file. The --voice CLI flag still takes precedence. Resolution order: --voice flag > CC_VOICE env > config file.
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.
Summary
CC_VOICEenvironment variable toplugins/voice/scripts/sayso the voice can be set per-process without mutating~/.claude/voice.local.md.--voiceCLI flag still takes precedence overCC_VOICE, which takes precedence over the config file.--helpoutput andplugins/voice/README.md.Motivation
Multi-agent setups want a distinct voice per agent so the user can tell speakers apart by ear. The config file is a single global value, and threading
--voicethrough every call site is awkward. SettingCC_VOICEonce in the agent's env (e.g. via the launcher, a wrapper script, or a hook that exports it before the agent runs) gives each concurrent agent its own voice with no shared-state contention.Test plan
CC_VOICE=eponine ./scripts/say "test"plays in eponine voice./scripts/say --voice alba "test"still wins when both--voiceandCC_VOICEare set./scripts/say --helplistsCC_VOICEvibe coded with care