From 13edce3671b80c3c9cd82da6d1bcc784f1e1f0f0 Mon Sep 17 00:00:00 2001 From: Johannes Altmanninger Date: Wed, 15 Dec 2021 17:59:12 +0100 Subject: [PATCH] share/**.fish: reformat with fish_indent --- share/completions/chgrp.fish | 42 +++++++++---------- share/completions/chmod.fish | 32 +++++++------- share/completions/chown.fish | 32 +++++++------- share/completions/color.fish | 14 +++---- share/completions/cut.fish | 36 ++++++++-------- share/completions/dscacheutil.fish | 2 +- share/completions/env.fish | 2 +- share/completions/findstr.fish | 14 +++---- share/completions/fish_opt.fish | 2 +- share/completions/opam.fish | 22 +++++----- share/completions/pabcnetcclear.fish | 14 +++---- share/completions/set.fish | 32 +++++++------- .../functions/__fish_config_interactive.fish | 2 +- 13 files changed, 123 insertions(+), 123 deletions(-) diff --git a/share/completions/chgrp.fish b/share/completions/chgrp.fish index 39387540e..7e17d6a54 100644 --- a/share/completions/chgrp.fish +++ b/share/completions/chgrp.fish @@ -1,24 +1,24 @@ if chgrp --version &>/dev/null # not unix - complete -c chgrp -s c -l changes -d "Output diagnostic for changed files" - complete -c chgrp -l dereference -d "Dereference symlinks" - complete -c chgrp -s h -l no-dereference -d "Don't dereference symlinks" - complete -c chgrp -l from -d "Change from owner/group" - complete -c chgrp -s f -l silent -d "Suppress errors" - complete -c chgrp -l reference -d "Use same owner/group as file" -r - complete -c chgrp -s R -l recursive -d "Operate recursively" - complete -c chgrp -s v -l verbose -d "Output diagnostic for every file" - complete -c chgrp -l help -d "Display help and exit" - complete -c chgrp -l version -d "Display version and exit" - complete -c chgrp -d Group -a "(__fish_complete_groups)" + complete -c chgrp -s c -l changes -d "Output diagnostic for changed files" + complete -c chgrp -l dereference -d "Dereference symlinks" + complete -c chgrp -s h -l no-dereference -d "Don't dereference symlinks" + complete -c chgrp -l from -d "Change from owner/group" + complete -c chgrp -s f -l silent -d "Suppress errors" + complete -c chgrp -l reference -d "Use same owner/group as file" -r + complete -c chgrp -s R -l recursive -d "Operate recursively" + complete -c chgrp -s v -l verbose -d "Output diagnostic for every file" + complete -c chgrp -l help -d "Display help and exit" + complete -c chgrp -l version -d "Display version and exit" + complete -c chgrp -d Group -a "(__fish_complete_groups)" else # not Linux - complete -c chgrp -s h -d "Don't dereference symlinks" - complete -c chgrp -s H -d "Follow specified symlinks with -R" - complete -c chgrp -s L -d "Follow all symlinks with -R" - complete -c chgrp -s P -d "Follow no symlinks with -R" - complete -c chgrp -s f -d "Suppress errors" - complete -c chgrp -s n -d "id is numeric; avoid lookup" - complete -c chgrp -s R -d "Operate recursively" - complete -c chgrp -s v -d "Output filenames" - complete -c chgrp -s x -d "Don't traverse fs mountpoints" - complete -c chgrp -d Group -a "(__fish_complete_groups)" + complete -c chgrp -s h -d "Don't dereference symlinks" + complete -c chgrp -s H -d "Follow specified symlinks with -R" + complete -c chgrp -s L -d "Follow all symlinks with -R" + complete -c chgrp -s P -d "Follow no symlinks with -R" + complete -c chgrp -s f -d "Suppress errors" + complete -c chgrp -s n -d "id is numeric; avoid lookup" + complete -c chgrp -s R -d "Operate recursively" + complete -c chgrp -s v -d "Output filenames" + complete -c chgrp -s x -d "Don't traverse fs mountpoints" + complete -c chgrp -d Group -a "(__fish_complete_groups)" end diff --git a/share/completions/chmod.fish b/share/completions/chmod.fish index cf3307ce7..74e95299d 100644 --- a/share/completions/chmod.fish +++ b/share/completions/chmod.fish @@ -1,19 +1,19 @@ if chmod --version &>/dev/null # gnu's not unix - complete chmod -s c -l changes -d 'Like -v but report only changes' - complete chmod -l no-preserve-root -d 'Don\'t treat / special (default)' - complete chmod -l preserve-root -d 'Fail to operate recursively on /' - complete chmod -s f -l silent -l quiet -d 'Suppress most errors' - complete chmod -s v -l verbose -d 'Prints each file processed' - complete chmod -l reference -d 'Use RFILEs mode instead of MODE values' -r - complete chmod -s R -l recursive -d 'Operate recursively' - complete chmod -l help -d 'Display help and exit' - complete chmod -l version -d 'Display version and exit' + complete chmod -s c -l changes -d 'Like -v but report only changes' + complete chmod -l no-preserve-root -d 'Don\'t treat / special (default)' + complete chmod -l preserve-root -d 'Fail to operate recursively on /' + complete chmod -s f -l silent -l quiet -d 'Suppress most errors' + complete chmod -s v -l verbose -d 'Prints each file processed' + complete chmod -l reference -d 'Use RFILEs mode instead of MODE values' -r + complete chmod -s R -l recursive -d 'Operate recursively' + complete chmod -l help -d 'Display help and exit' + complete chmod -l version -d 'Display version and exit' else # guess it might be unix - complete chmod -s f -d 'Suppress errors' - complete chmod -s H -d "Follow given symlinks with -R" - complete chmod -s h -d "Don't dereference given symlinks" - complete chmod -s L -d "Follow all symlinks with -R" - complete chmod -s P -d "Follow no symlinks with -R" - complete chmod -s R -d 'Operate recursively' - complete chmod -s v -d 'Prints each file processed' + complete chmod -s f -d 'Suppress errors' + complete chmod -s H -d "Follow given symlinks with -R" + complete chmod -s h -d "Don't dereference given symlinks" + complete chmod -s L -d "Follow all symlinks with -R" + complete chmod -s P -d "Follow no symlinks with -R" + complete chmod -s R -d 'Operate recursively' + complete chmod -s v -d 'Prints each file processed' end diff --git a/share/completions/chown.fish b/share/completions/chown.fish index 9ca348a70..201d155f5 100644 --- a/share/completions/chown.fish +++ b/share/completions/chown.fish @@ -1,21 +1,21 @@ if chown --version &>/dev/null # gee, and you is not eunichs - complete chown -s c -l changes -d "Output diagnostic for changed files" - complete chown -l dereference -d "Dereference symbolic links" - complete chown -s h -l no-dereference -d "Do not dereference symbolic links" - complete chown -l from -d "Change from owner/group" - complete chown -s f -l silent -d "Suppress errors" - complete chown -l reference -d "Use same owner/group as file" -r - complete chown -s R -l recursive -d "Operate recursively" - complete chown -s v -l verbose -d "Output diagnostic for every file" - complete chown -l help -d "Display help and exit" - complete chown -l version -d "Display version and exit" + complete chown -s c -l changes -d "Output diagnostic for changed files" + complete chown -l dereference -d "Dereference symbolic links" + complete chown -s h -l no-dereference -d "Do not dereference symbolic links" + complete chown -l from -d "Change from owner/group" + complete chown -s f -l silent -d "Suppress errors" + complete chown -l reference -d "Use same owner/group as file" -r + complete chown -s R -l recursive -d "Operate recursively" + complete chown -s v -l verbose -d "Output diagnostic for every file" + complete chown -l help -d "Display help and exit" + complete chown -l version -d "Display version and exit" else - complete chown -s R -d 'Operate recursively' - complete chown -s f -d "Suppress errors" - complete chown -s h -d "Do not dereference symbolic links" - complete chown -s n -d "uid/gid is numeric; avoid lookup" - complete chown -s v -d "Output filenames as modified" - complete chown -s x -d "Don't traverse fs mount points" + complete chown -s R -d 'Operate recursively' + complete chown -s f -d "Suppress errors" + complete chown -s h -d "Do not dereference symbolic links" + complete chown -s n -d "uid/gid is numeric; avoid lookup" + complete chown -s v -d "Output filenames as modified" + complete chown -s x -d "Don't traverse fs mount points" end complete chown -s H -d "Follow given symlinks with -R" diff --git a/share/completions/color.fish b/share/completions/color.fish index a8e192fe9..7b4d4185f 100644 --- a/share/completions/color.fish +++ b/share/completions/color.fish @@ -1,10 +1,10 @@ function __color_generate_args --description 'Function to generate args' - set --local current_token (commandline --current-token --cut-at-cursor) - switch $current_token - case '/*' - echo -e '/?\tShow help' - case '*' - echo -e '0\tBlack + set --local current_token (commandline --current-token --cut-at-cursor) + switch $current_token + case '/*' + echo -e '/?\tShow help' + case '*' + echo -e '0\tBlack 1\tBlue 2\tGreen 3\tAqua @@ -20,7 +20,7 @@ C\tLight red D\tLight purple E\tLight yellow F\tBright white' | awk -F '\t' "{ printf \"$current_token%s\t%s\n\", \$1, \$2 }" - end + end end complete --command color --no-files --arguments '(__color_generate_args)' diff --git a/share/completions/cut.fish b/share/completions/cut.fish index 4e6823a6c..21f23682b 100644 --- a/share/completions/cut.fish +++ b/share/completions/cut.fish @@ -1,21 +1,21 @@ if cut --version &>/dev/null - complete -c cut -s b -l bytes -x -d "Select byte positions" - complete -c cut -s c -l characters -x -d "Select characters" - complete -c cut -s d -l delimiter -x -d "Select field delimiter" - complete -c cut -s f -l fields -x -d "Select fields" - complete -c cut -s n -d "Don't split multi-byte characters" - complete -c cut -l complement -d "complement the set of selected bytes, characters or fields" - complete -c cut -s s -l only-delimited -d "Suppress lines without delimiter" - complete -c cut -l output-delimiter -x -d "Select output delimiter" - complete -c cut -s z -l zero-terminated -d "line delimiter is NUL, not newline" - complete -c cut -l help -d "Display help and exit" - complete -c cut -l version -d "Display version and exit" + complete -c cut -s b -l bytes -x -d "Select byte positions" + complete -c cut -s c -l characters -x -d "Select characters" + complete -c cut -s d -l delimiter -x -d "Select field delimiter" + complete -c cut -s f -l fields -x -d "Select fields" + complete -c cut -s n -d "Don't split multi-byte characters" + complete -c cut -l complement -d "complement the set of selected bytes, characters or fields" + complete -c cut -s s -l only-delimited -d "Suppress lines without delimiter" + complete -c cut -l output-delimiter -x -d "Select output delimiter" + complete -c cut -s z -l zero-terminated -d "line delimiter is NUL, not newline" + complete -c cut -l help -d "Display help and exit" + complete -c cut -l version -d "Display version and exit" else - complete -c cut -s b -x -d "Select byte positions" - complete -c cut -s c -x -d "Output character range" - complete -c cut -s d -x -d "Delimiter instead of \t to use" - complete -c cut -s f -x -d "Select fields" - complete -c cut -s n -d "Don't split multi-byte characters" - complete -c cut -s s -d "Supress lines without delimiter" - complete -c cut -s w -d "Use whitespace as delimiter" + complete -c cut -s b -x -d "Select byte positions" + complete -c cut -s c -x -d "Output character range" + complete -c cut -s d -x -d "Delimiter instead of \t to use" + complete -c cut -s f -x -d "Select fields" + complete -c cut -s n -d "Don't split multi-byte characters" + complete -c cut -s s -d "Supress lines without delimiter" + complete -c cut -s w -d "Use whitespace as delimiter" end diff --git a/share/completions/dscacheutil.fish b/share/completions/dscacheutil.fish index 85819bee2..72462c565 100644 --- a/share/completions/dscacheutil.fish +++ b/share/completions/dscacheutil.fish @@ -1,6 +1,6 @@ # dscacheutil complete -c dscacheutil -f -d 'Directory Service cache utility' -complete -c dscacheutil -s h -d 'lists options' -f -n '[ (commandline -opc | count) -le 1 ]' +complete -c dscacheutil -s h -d 'lists options' -f -n '[ (commandline -opc | count) -le 1 ]' complete -c dscacheutil -s q -d 'initiate query' -f -x -n '[ (commandline -opc | count) -le 1 ] || contains -- -a (commandline -opc) || contains -- -q (commandline -opc) && [ (commandline -opc | count) -lt 3 ]' -a " group\t'name or gid' host\t'name or ip address' diff --git a/share/completions/env.fish b/share/completions/env.fish index 0225e4adf..087c5d9d5 100644 --- a/share/completions/env.fish +++ b/share/completions/env.fish @@ -1,4 +1,4 @@ -if env --version &> /dev/null +if env --version &>/dev/null set -l is_gnu --is-gnu end diff --git a/share/completions/findstr.fish b/share/completions/findstr.fish index 47892995a..c4144e2ef 100644 --- a/share/completions/findstr.fish +++ b/share/completions/findstr.fish @@ -1,8 +1,8 @@ function __findstr_generate_args --description 'Function to generate args' - set --local current_token (commandline --current-token --cut-at-cursor) - switch $current_token - case '/a:*' - echo -e '0\tBlack + set --local current_token (commandline --current-token --cut-at-cursor) + switch $current_token + case '/a:*' + echo -e '0\tBlack 1\tBlue 2\tGreen 3\tAqua @@ -18,8 +18,8 @@ C\tLight red D\tLight purple E\tLight yellow F\tBright white' | awk -F '\t' "{ printf \"$current_token%s\t%s\n\", \$1, \$2 }" - case '*' - echo -e '/b\tMatch at the beginning of the line + case '*' + echo -e '/b\tMatch at the beginning of the line /e\tMatch at the end of the line /l\tUse literal strings /r\tUse regular expressions @@ -39,7 +39,7 @@ F\tBright white' | awk -F '\t' "{ printf \"$current_token%s\t%s\n\", \$1, \$2 }" /d:\tSpecify the search list of directories /a:\tUse color attributes with two hexadecimal digits /?\tShow help' - end + end end complete --command findstr --no-files --arguments '(__findstr_generate_args)' diff --git a/share/completions/fish_opt.fish b/share/completions/fish_opt.fish index ef161709e..e2d317ad8 100644 --- a/share/completions/fish_opt.fish +++ b/share/completions/fish_opt.fish @@ -8,5 +8,5 @@ complete --command fish_opt --short-option s --long-option short --no-files --re complete --command fish_opt --short-option l --long-option long --no-files --require-parameter --description 'Specify long option' complete --command fish_opt --long-option longonly --description 'Use only long option' complete --command fish_opt --short-option o --long-option optional-val -n $CONDITION --description 'Don\'t require value' -complete --command fish_opt --short-option r --long-option required-val -n $CONDITION --description 'Require value' +complete --command fish_opt --short-option r --long-option required-val -n $CONDITION --description 'Require value' complete --command fish_opt --long-option multiple-vals --description 'Store all values' diff --git a/share/completions/opam.fish b/share/completions/opam.fish index 1738586bd..f2db2ec79 100644 --- a/share/completions/opam.fish +++ b/share/completions/opam.fish @@ -105,17 +105,17 @@ complete -f -c opam -n '__fish_opam_using_command admin' -a stats -d "Compute st # opam switch set -l switchcommands create set remove export import reinstall list list-available show set-base set-description link -complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a 'create' -d 'Create a new switch, and install the given compiler there' -complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a 'set' -d 'Set the currently active switch' -complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a 'remove' -d 'Remove the given switch from disk' -complete -c opam -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a 'export' -d 'Save the current switch state to a file' -complete -c opam -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a 'import' -d 'Import a saved switch state' -complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a 'reinstall' -d 'Reinstall the given compiler switch and all its packages' -complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a 'list' -d 'Lists installed switches' -complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a 'list-available' -d 'Lists base packages that can be used to create a new switch' -complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a 'show' -d 'Prints the name of the current switch' -complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a 'set-base' -d 'Sets the packages forming the immutable base for the selected switch' -complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a 'link' -d 'Sets a local alias for a given switch' +complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a create -d 'Create a new switch, and install the given compiler there' +complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a set -d 'Set the currently active switch' +complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a remove -d 'Remove the given switch from disk' +complete -c opam -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a export -d 'Save the current switch state to a file' +complete -c opam -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a import -d 'Import a saved switch state' +complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a reinstall -d 'Reinstall the given compiler switch and all its packages' +complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a list -d 'Lists installed switches' +complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a list-available -d 'Lists base packages that can be used to create a new switch' +complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a show -d 'Prints the name of the current switch' +complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a set-base -d 'Sets the packages forming the immutable base for the selected switch' +complete -c opam -f -n "__fish_seen_subcommand_from switch; and not __fish_seen_subcommand_from $switchcommands" -a link -d 'Sets a local alias for a given switch' complete -c opam -f -n "__fish_seen_subcommand_from switch; and __fish_seen_subcommand_from set" -a '(opam switch list --short)' complete -c opam -f -n "__fish_seen_subcommand_from switch; and __fish_seen_subcommand_from remove" -a '(opam switch list --short)' diff --git a/share/completions/pabcnetcclear.fish b/share/completions/pabcnetcclear.fish index 11b1e4e12..2d1af57ea 100644 --- a/share/completions/pabcnetcclear.fish +++ b/share/completions/pabcnetcclear.fish @@ -1,20 +1,20 @@ # Completion for: PascalABC.NET 3.8.1 compiler function __pabcnetcclear_generate_args --description 'Function to generate args' - set --local current_token (commandline --current-token --cut-at-cursor) - switch $current_token - case '/Debug:*' - echo -e $current_token"0\tEnable generation + set --local current_token (commandline --current-token --cut-at-cursor) + switch $current_token + case '/Debug:*' + echo -e $current_token"0\tEnable generation $current_token"1"\tDisable generation" - case '*' - echo -e "/Help\tShow help + case '*' + echo -e "/Help\tShow help /H\tShow help /?\tShow help /Debug\tGenerate a code debug info /output\tSpecify an executable name /SearchDir\tSpecify a path to search units /define\tDefine a symbol" - end + end end complete --command pabcnetcclear --no-files --arguments '(__pabcnetcclear_generate_args)' diff --git a/share/completions/set.fish b/share/completions/set.fish index 1af231f75..87f59547d 100644 --- a/share/completions/set.fish +++ b/share/completions/set.fish @@ -51,22 +51,22 @@ end function __fish_complete_special_vars printf "%s\t%s\n" \ - PATH "list of dirs to look for commands in" \ - CDPATH "list of dirs under which that cd searches" \ - FISH_DEBUG "list of enabled debug categories" \ - FISH_DEBUG_OUTPUT "debug output path" \ - umask "current file creation mask" \ - fish_handle_reflow "if fish should repaint prompt when the term resizes" \ - fish_trace "print cmds as they execute, like set -x" \ - fish_emoji_width "cols wide fish assumes emoji render as" \ - fish_key_bindings "name of function that sets binds" \ - fish_autosuggestion_enabled "turns autosuggestions on or off" \ - fish_ambiguous_width "affects computed width of east asian chars" \ - fish_escape_delay_ms "How long fish waits to distinguish escape and alt" \ - fish_greeting "The message to display at start (also a function)" \ - fish_history "The session id to store history under" \ - fish_trace "Enables execution tracing (if set to non-empty value)" \ - fish_user_paths "A list of dirs to prepend to PATH" + PATH "list of dirs to look for commands in" \ + CDPATH "list of dirs under which that cd searches" \ + FISH_DEBUG "list of enabled debug categories" \ + FISH_DEBUG_OUTPUT "debug output path" \ + umask "current file creation mask" \ + fish_handle_reflow "if fish should repaint prompt when the term resizes" \ + fish_trace "print cmds as they execute, like set -x" \ + fish_emoji_width "cols wide fish assumes emoji render as" \ + fish_key_bindings "name of function that sets binds" \ + fish_autosuggestion_enabled "turns autosuggestions on or off" \ + fish_ambiguous_width "affects computed width of east asian chars" \ + fish_escape_delay_ms "How long fish waits to distinguish escape and alt" \ + fish_greeting "The message to display at start (also a function)" \ + fish_history "The session id to store history under" \ + fish_trace "Enables execution tracing (if set to non-empty value)" \ + fish_user_paths "A list of dirs to prepend to PATH" end # diff --git a/share/functions/__fish_config_interactive.fish b/share/functions/__fish_config_interactive.fish index 64cb7b41a..614cd93da 100644 --- a/share/functions/__fish_config_interactive.fish +++ b/share/functions/__fish_config_interactive.fish @@ -28,7 +28,7 @@ function __fish_config_interactive -d "Initializations that should be performed # If we are starting up for the first time, set various defaults. if test $__fish_initialized -lt 3400 - # Regular syntax highlighting colors + # Regular syntax highlighting colors __init_uvar fish_color_normal normal __init_uvar fish_color_command blue __init_uvar fish_color_param cyan