Skip to content

Commit

Permalink
Removed deprecated -A option from fish completion
Browse files Browse the repository at this point in the history
Co-authored-by: Jürn Brodersen <[email protected]>
  • Loading branch information
Secrus and JB26 committed Oct 25, 2023
1 parent 8394f10 commit 3465582
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/cleo/commands/completions_command.py
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ def sanitize(s: str) -> str:
cmds_opts += [
f"# {cmd.name}",
*[
f"complete -c {script_name} -A "
f"complete -c {script_name} "
f"-n '{condition}' "
f"-l {opt.name} -d '{sanitize(opt.description)}'"
for opt in sorted(cmd.definition.options, key=lambda o: o.name)
Expand Down
8 changes: 4 additions & 4 deletions tests/commands/completion/fixtures/fish.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,15 @@ complete -c script -f -n '__fish_seen_subcommand_from spaced; and not __fish_see
# command options

# command:with:colons
complete -c script -A -n '__fish_seen_subcommand_from command:with:colons' -l goodbye -d ''
complete -c script -n '__fish_seen_subcommand_from command:with:colons' -l goodbye -d ''

# hello
complete -c script -A -n '__fish_seen_subcommand_from hello' -l dangerous-option -d 'This $hould be `escaped`.'
complete -c script -A -n '__fish_seen_subcommand_from hello' -l option-without-description -d ''
complete -c script -n '__fish_seen_subcommand_from hello' -l dangerous-option -d 'This $hould be `escaped`.'
complete -c script -n '__fish_seen_subcommand_from hello' -l option-without-description -d ''

# help

# list

# spaced command
complete -c script -A -n '__fish_seen_subcommand_from spaced; and __fish_seen_subcommand_from command' -l goodbye -d ''
complete -c script -n '__fish_seen_subcommand_from spaced; and __fish_seen_subcommand_from command' -l goodbye -d ''

0 comments on commit 3465582

Please sign in to comment.