remove q quit alias

`q` was introduced in round-5 as a peer Keyword variant alongside
`quit`. Per ADR-0023's "alias miss" critique, that was the wrong
shape — it surfaced `q` as a standalone command in completion
(only one of its kind), and required parallel parser + usage +
catalog + test entries. Drops the Keyword variant entirely; if
this ever needs to come back, it should arrive as an alias
annotation per ADR-0023, not as a peer keyword.

Tests still 769 passing.
This commit is contained in:
claude@clouddev1
2026-05-13 22:36:42 +00:00
parent 6ca297579e
commit a55b6a7a05
6 changed files with 9 additions and 19 deletions
-1
View File
@@ -112,7 +112,6 @@ define_keywords! {
// routing so these work in both simple and advanced modes
// (per ADR-0003).
Quit => "quit",
Q => "q",
Help => "help",
Rebuild => "rebuild",
Save => "save",
+1 -2
View File
@@ -469,8 +469,7 @@ fn command_parser<'a>()
// BEFORE chumsky runs; the bare-keyword forms below
// surface the `Path: None` / no-source variants for
// empty-prompt completion + usage rendering.
let quit_cmd = choice((kw(Keyword::Quit), kw(Keyword::Q)))
.map(|()| Command::App(AppCommand::Quit));
let quit_cmd = kw(Keyword::Quit).map(|()| Command::App(AppCommand::Quit));
let help_cmd = kw(Keyword::Help).map(|()| Command::App(AppCommand::Help));
let rebuild_cmd =
kw(Keyword::Rebuild).map(|()| Command::App(AppCommand::Rebuild));
+4 -10
View File
@@ -99,10 +99,6 @@ pub const REGISTRY: &[UsageEntry] = &[
entry: Keyword::Quit,
catalog_key: "parse.usage.quit",
},
UsageEntry {
entry: Keyword::Q,
catalog_key: "parse.usage.quit",
},
UsageEntry {
entry: Keyword::Help,
catalog_key: "parse.usage.help",
@@ -220,7 +216,6 @@ mod tests {
Keyword::Delete,
Keyword::Replay,
Keyword::Quit,
Keyword::Q,
Keyword::Help,
Keyword::Rebuild,
Keyword::Save,
@@ -308,16 +303,15 @@ mod tests {
fn entry_keywords_alphabetised_returns_unique_sorted_commands() {
let keys = entry_keywords_alphabetised();
let names: Vec<&str> = keys.iter().map(|k| k.as_str()).collect();
// Ten DSL entries plus the eleven app-lifecycle entries
// registered in REGISTRY (quit/q are two keywords with
// the same usage template; both surface here).
// Ten DSL entries plus the ten app-lifecycle entries
// registered in REGISTRY.
assert_eq!(
names,
vec![
"add", "change", "create", "delete", "drop", "export",
"help", "import", "insert", "load", "messages", "mode",
"new", "q", "quit", "rebuild", "rename", "replay",
"save", "show", "update",
"new", "quit", "rebuild", "rename", "replay", "save",
"show", "update",
],
);
}