Skip to content

Commit

Permalink
fix(fish): cache usage spec in global
Browse files Browse the repository at this point in the history
In universal it will be cached forever
  • Loading branch information
jdx committed Nov 10, 2024
1 parent 356c04f commit 0b06c6c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/src/complete/fish.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ end"#
out.push(format!(
r#"
if ! set -q {spec_variable}
set -U {spec_variable} ({usage_cmd} | string collect)
set -g {spec_variable} ({usage_cmd} | string collect)
end"#
));
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,6 @@ if ! command -v usage &> /dev/null
end

if ! set -q _usage_spec_mycli_1_2_3
set -U _usage_spec_mycli_1_2_3 (mycli complete --usage | string collect)
set -g _usage_spec_mycli_1_2_3 (mycli complete --usage | string collect)
end
complete -xc mycli -a '(usage complete-word --shell fish -s "$_usage_spec_mycli_1_2_3" -- (commandline -cop) (commandline -t))'

0 comments on commit 0b06c6c

Please sign in to comment.