mirror of
https://github.com/fish-shell/fish-shell.git
synced 2025-03-27 14:45:13 +08:00
abbr: Stop escaping the name for abbr --list
This is so we can pass it to `abbr --erase`. Fixes #9470
This commit is contained in:
parent
572a568268
commit
1b1cf73b60
@ -139,7 +139,7 @@ static int abbr_list(const abbr_options_t &opts, io_streams_t &streams) {
|
|||||||
}
|
}
|
||||||
const auto abbrs = abbrs_get_set();
|
const auto abbrs = abbrs_get_set();
|
||||||
for (const auto &abbr : abbrs->list()) {
|
for (const auto &abbr : abbrs->list()) {
|
||||||
wcstring name = escape_string(abbr.name);
|
wcstring name = abbr.name;
|
||||||
name.push_back(L'\n');
|
name.push_back(L'\n');
|
||||||
streams.out.append(name);
|
streams.out.append(name);
|
||||||
}
|
}
|
||||||
|
@ -180,7 +180,13 @@ echo erase $status
|
|||||||
set --show _fish_abbr_cuckoo
|
set --show _fish_abbr_cuckoo
|
||||||
# Nothing
|
# Nothing
|
||||||
|
|
||||||
|
abbr --add '$PAGER' less
|
||||||
abbr --erase (abbr --list)
|
abbr --erase (abbr --list)
|
||||||
|
abbr --list
|
||||||
|
# Nothing
|
||||||
|
abbr --add '$PAGER' less
|
||||||
|
abbr --list
|
||||||
|
# CHECK: $PAGER
|
||||||
|
|
||||||
abbr --add bogus --position never stuff
|
abbr --add bogus --position never stuff
|
||||||
# CHECKERR: abbr: Invalid position 'never'
|
# CHECKERR: abbr: Invalid position 'never'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user