fish-shell/share/functions
ridiculousfish 06400b83b1 Support for command wrapping ("aliases")
Add the --wraps option to 'complete' and 'function'. This allows a
command to (recursively) inherit the completions of a wrapped command.
Fixes #393.

When evaluating a completion, we inspect the entire "wrap chain" for a
command, i.e. we follow the sequence of wrapping until we either hit a
loop (which we silently ignore) or the end of the chain. We then
evaluate completions as if the wrapping command were substituted with
the wrapped command. Currently this only works for commands, i.e.
'complete --command gco --wraps git\ checkout' won't work (that would
seem to encroaching on abbreviations anyways). It might be useful to
show an error message for that case.

The commandline builtin reflects the commandline with the wrapped
command substituted in, so e.g. git completions (which inspect the
command line) will just work. This sort of command line munging is
also performed by 'complete -C' so it's not totally without precedent.

'alias will also now mark its generated function as wrapping the
'target.
2014-08-15 18:14:36 -07:00
..
_.fish Make gettext function use echo instead of printf to save a fork 2012-04-25 13:37:41 -07:00
__fish_append.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
__fish_bind_test1.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_bind_test2.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
__fish_commandline_test.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_complete_abook_formats.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_complete_ant_targets.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
__fish_complete_atool.fish Squashed commit of the following: 2013-04-01 10:49:02 -07:00
__fish_complete_atool_archive_contents.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_complete_aura.fish adding completion for aura. adding pacman integration for __fish_print_packages 2014-02-16 18:09:55 +08:00
__fish_complete_bittorrent.fish Drop use of the N_ no-op for translation descriptions. Instead, tell xgettext that any token following '--description' should be translated. This should greatly speed up completion loading on platforms where fork() is slow. (Hi, OS X) 2007-01-16 11:18:28 +10:00
__fish_complete_cabal.fish Add completions for cabal; closes #567 2013-05-04 12:48:38 -07:00
__fish_complete_cd.fish Fix indentation in __fish_complete_cd 2013-11-26 00:07:18 -08:00
__fish_complete_command.fish Fix other usages of \n in sed replacements. 2012-06-17 15:01:04 -07:00
__fish_complete_convert_options.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_complete_diff.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_complete_directories.fish Minor polish like adding missing whitespace, switch to using --argument switch in function definitions to make code more readable, add a few minor saftey checks, etc. 2007-09-24 07:07:30 +10:00
__fish_complete_file_url.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
__fish_complete_ftp.fish Fixed ftp completions 2013-07-18 21:26:32 +05:30
__fish_complete_grep.fish grep: add support for egrep, fgrep, rgrep 2013-04-07 16:42:28 -07:00
__fish_complete_groups.fish use getent for passwd and group if available 2012-11-27 11:49:52 +08:00
__fish_complete_list.fish Squashed commit of the following: 2013-04-01 10:49:02 -07:00
__fish_complete_lpr.fish Remove trailing whitespaces and change tabs to spaces 2012-11-18 11:23:22 +01:00
__fish_complete_lpr_option.fish Fix other usages of \n in sed replacements. 2012-06-17 15:01:04 -07:00
__fish_complete_ls.fish Fix some typos. 2013-09-12 11:46:31 +02:00
__fish_complete_lsusb.fish Rename __fish_complete_usb function. 2014-01-14 08:28:15 +01:00
__fish_complete_man.fish __fish_complete_man: Use awk to parse output of apropos 2013-11-27 17:58:43 +08:00
__fish_complete_mime.fish Remove explicit directory completion from __fish_complete_mime, we only want directory completion as a fallback in order to minimize the number of reasonable completions that are ignored. This issue was reported by Claes Nästén. 2007-04-18 08:56:58 +10:00
__fish_complete_pacman.fish adding completion for aura. adding pacman integration for __fish_print_packages 2014-02-16 18:09:55 +08:00
__fish_complete_pgrep.fish Squashed commit of the following: 2013-04-01 10:49:02 -07:00
__fish_complete_pids.fish Fix proc and pid completion on OS X, and improve it on Linux. 2013-01-16 14:11:43 -08:00
__fish_complete_ppp_peer.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_complete_proc.fish Fix proc and pid completion on OS X, and improve it on Linux. 2013-01-16 14:11:43 -08:00
__fish_complete_python.fish Fix python completion to work for pypy 2014-05-03 15:06:57 -07:00
__fish_complete_service_actions.fish Add eselect, rc-update and rc-service completions. (These are utilities used by Gentoo Linux) 2013-11-27 18:36:05 +08:00
__fish_complete_setxkbmap.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_complete_ssh.fish Squashed commit of the following: 2013-04-01 10:49:02 -07:00
__fish_complete_subcommand.fish Remove trailing whitespaces and change tabs to spaces 2012-11-18 11:23:22 +01:00
__fish_complete_subcommand_root.fish reviewed merge reqest 14: 2012-01-25 01:14:47 +01:00
__fish_complete_suffix.fish * __fish_complete_subcommand_root now passes arguments to 2011-09-23 12:24:21 +04:00
__fish_complete_svn.fish __fish_complete_svn: remove GNU extension options 2013-12-30 12:32:24 +08:00
__fish_complete_svn_diff.fish Remove trailing whitespaces and change tabs to spaces 2012-11-18 11:23:22 +01:00
__fish_complete_tar.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
__fish_complete_tex.fish Squashed commit of the following: 2013-04-01 10:49:02 -07:00
__fish_complete_unrar.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
__fish_complete_users.fish use getent for passwd and group if available 2012-11-27 11:49:52 +08:00
__fish_complete_vi.fish Retab again 2014-01-20 17:12:32 +04:00
__fish_complete_wvdial_peers.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_complete_xsum.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_config_interactive.fish Merge branch 'master' into 1218_rebase 2014-03-29 14:19:45 -07:00
__fish_contains_opt.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
__fish_crux_packages.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
__fish_cursor_konsole.fish Add tmux support 2014-01-20 21:28:54 +04:00
__fish_cursor_xterm.fish Retab again 2014-01-20 17:12:32 +04:00
__fish_describe_command.fish Get rid of 'nothing appropriate' output when completing. 2012-08-04 11:20:03 -07:00
__fish_filter_ant_targets.fish Improve ant completions. This patch comes from Steven Knight. (minor tweaks applied) 2008-01-09 08:16:08 +10:00
__fish_filter_mime.fish Fix __fish_filter_mime to not pass 0 to seq 2013-04-28 15:59:33 -07:00
__fish_git_prompt.fish Fix non-verbose, non-informative __fish_git_prompt 2014-03-31 09:59:41 -07:00
__fish_gnu_complete.fish Squashed commit of the following: 2013-04-01 10:49:02 -07:00
__fish_is_first_token.fish Drop unneeded '--' when using set builtin in various places 2006-12-13 06:37:27 +10:00
__fish_is_token_n.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_list_current_token.fish Add newline before listing current token. 2013-09-13 14:30:13 +08:00
__fish_make_completion_signals.fish Squashed commit of the following: 2013-04-01 10:49:02 -07:00
__fish_move_last.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
__fish_no_arguments.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
__fish_not_contain_opt.fish Squashed commit of the following: 2013-04-01 10:49:02 -07:00
__fish_number_of_cmd_args_wo_opts.fish Add eselect, rc-update and rc-service completions. (These are utilities used by Gentoo Linux) 2013-11-27 18:36:05 +08:00
__fish_paginate.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
__fish_ports_dirs.fish Completions for ports, a tool for port management in CRUX linux 2007-08-04 21:09:16 +10:00
__fish_print_abook_emails.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_print_addresses.fish Clean up interactive mode init a bit. Move a few utility functions to their own files. 2007-09-22 06:52:12 +10:00
__fish_print_arch_daemons.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_print_cmd_args.fish Add eselect, rc-update and rc-service completions. (These are utilities used by Gentoo Linux) 2013-11-27 18:36:05 +08:00
__fish_print_cmd_args_without_options.fish Add eselect, rc-update and rc-service completions. (These are utilities used by Gentoo Linux) 2013-11-27 18:36:05 +08:00
__fish_print_commands.fish Teach fish_print_commands how to use __fish_datadir 2012-12-27 00:46:54 -08:00
__fish_print_debian_services.fish adds completion for Debian's invoke-rc.d command 2009-02-05 05:17:57 +10:00
__fish_print_encodings.fish Create common function for listing available character encodings, make sure it is used in all relevant places. 2007-09-22 07:10:51 +10:00
__fish_print_filesystems.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
__fish_print_function_prototypes.fish Add functiopn prototype completions for valgrind --alloc-fn 2006-02-24 23:56:18 +10:00
__fish_print_help.fish Remove trailing whitespaces and change tabs to spaces 2012-11-18 11:23:22 +01:00
__fish_print_hostnames.fish Fixed appearance of ssh hostnames with [] in them 2014-03-29 11:46:45 +01:00
__fish_print_interfaces.fish Clean up interactive mode init a bit. Move a few utility functions to their own files. 2007-09-22 06:52:12 +10:00
__fish_print_lpr_options.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_print_lpr_printers.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_print_lsblk_columns.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_print_make_targets.fish Support for escaped colons in makefile targets in __fish_print_make_targets, as part of #1259 2014-01-29 15:42:52 -08:00
__fish_print_mounted.fish Make __fish_print_mounted work better on OS X 2013-09-05 11:40:51 -07:00
__fish_print_packages.fish avoid symlink attacks in __fish_print_packages and spawning fishd 2014-05-12 09:30:05 +08:00
__fish_print_service_names.fish Fix bug for systemd being installed but not PID 1 2014-06-20 11:08:35 +08:00
__fish_print_svn_rev.fish Non standard cut options 2013-12-18 18:02:19 +02:00
__fish_print_users.fish Make __fish_print_users work on OS X via dscl 2014-08-12 14:42:49 -07:00
__fish_print_xdg_mimeapps.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_print_xdg_mimetypes.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_print_xrandr_modes.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_print_xrandr_outputs.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_print_xwindows.fish Squashed commit of the following: 2012-06-15 17:30:33 -07:00
__fish_prt_no_subcommand.fish Completions for prt-get and pkgutils, the package management utilities for CRUX (Giorgio Lando) 2007-08-04 06:22:53 +10:00
__fish_prt_packages.fish Completions for prt-get and pkgutils, the package management utilities for CRUX (Giorgio Lando) 2007-08-04 06:22:53 +10:00
__fish_prt_ports.fish Completions for prt-get and pkgutils, the package management utilities for CRUX (Giorgio Lando) 2007-08-04 06:22:53 +10:00
__fish_prt_use_package.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
__fish_prt_use_port.fish Completions for prt-get and pkgutils, the package management utilities for CRUX (Giorgio Lando) 2007-08-04 06:22:53 +10:00
__fish_pwd.fish Mac OS X doesn't support uname -o. Use uname instead. 2013-08-16 20:48:44 +02:00
__fish_seen_subcommand_from.fish Drop unneeded '--' when using set builtin in various places 2006-12-13 06:37:27 +10:00
__fish_systemctl_mounts.fish Functions instead of static variables for conditions. 2014-05-03 12:30:41 -07:00
__fish_systemctl_service_paths.fish Functions instead of static variables for conditions. 2014-05-03 12:30:41 -07:00
__fish_systemctl_services.fish Functions instead of static variables for conditions. 2014-05-03 12:30:41 -07:00
__fish_systemctl_sockets.fish Functions instead of static variables for conditions. 2014-05-03 12:30:41 -07:00
__fish_test_arg.fish Add vim completions, written by Velko Hristov 2007-01-30 10:42:33 +10:00
__fish_urlencode.fish add __fish_urlencode function which URL-escapes stdin 2013-09-04 20:30:42 +02:00
__fish_use_subcommand.fish Minor cleanups, mostly of code comments 2006-11-11 20:54:52 +10:00
__terlar_git_prompt.fish git prompt shouldn't export variables. 2014-06-01 09:39:28 +02:00
alias.fish Support for command wrapping ("aliases") 2014-08-15 18:14:36 -07:00
cd.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
contains_seq.fish fix output 2012-09-22 23:49:26 -07:00
delete-or-exit.fish Made C-d delete characters in multiple lines. 2012-06-07 21:18:02 +05:30
dirh.fish Remove trailing whitespaces and change tabs to spaces 2012-11-18 11:23:22 +01:00
dirs.fish Make all descriptions for function calls use the implicit translation from the previous patch instead of explicitly using N_ 2007-01-16 11:29:18 +10:00
down-or-search.fish Teach down-or-search how to use down-arrow to begin pager navigation 2014-01-25 15:32:13 -08:00
eval.fish Initial work towards various IO cleanups with an eye to fixing https://github.com/fish-shell/fish-shell/issues/110 2013-08-19 18:06:24 -07:00
fish_config.fish Fix check for non-empty argument (= initial tab) in fish_config 2012-08-30 13:17:32 +02:00
fish_default_key_bindings.fish Merge branch 'master' into 1218_rebase 2014-03-29 14:19:45 -07:00
fish_indent.fish Add function for fish_indent so that it does not need to be in PATH, in preparation for making fish no longer need to set PATH 2013-02-13 14:44:10 -08:00
fish_prompt.fish Add support for toor account. 2014-07-30 11:55:47 +02:00
fish_update_completions.fish Move autogenerated completions to ~/.config/fish/generated_completions/ 2013-02-17 16:14:36 -08:00
fish_vi_cursor.fish Add tmux support 2014-01-20 21:28:54 +04:00
fish_vi_key_bindings.fish Also add forward/backward movement in insert mode 2014-06-27 22:55:27 +08:00
fish_vi_mode.fish Set $fish_bind_mode to default on fish startup; set $fish_key_bindings 2014-01-19 10:27:39 +01:00
fish_vi_prompt.fish Add support for toor account. 2014-07-30 11:55:47 +02:00
funced.fish use mktemp(1) to generate temporary file names 2014-04-28 10:42:00 +08:00
funcsave.fish Update funced 2012-07-01 14:20:43 -07:00
grep.fish remove trialing spaces #2 2010-09-18 10:18:26 +08:00
help.fish Implement 'help' for Cygwin. 2013-08-13 17:26:38 +03:00
history.fish Remove trailing whitespaces and change tabs to spaces 2012-11-18 11:23:22 +01:00
hostname.fish Mac OS X doesn't support uname -o. Use uname instead. 2013-08-16 20:48:44 +02:00
isatty.fish Enhance/fix isatty using command test. 2014-01-28 11:14:54 -08:00
la.fish Make all descriptions for function calls use the implicit translation from the previous patch instead of explicitly using N_ 2007-01-16 11:29:18 +10:00
ll.fish Make all descriptions for function calls use the implicit translation from the previous patch instead of explicitly using N_ 2007-01-16 11:29:18 +10:00
ls.fish Fix ls command under Cygwin 2013-08-12 09:38:17 +03:00
man.fish Use manpath instead of man --path in man.fish function (as in commit 2013-10-03 11:46:58 +02:00
math.fish math.fish: exit if no output (e.g. from syntax error) 2014-02-05 17:26:34 +08:00
mimedb.fish Add function wrapper for mimedb 2013-02-17 12:56:56 -08:00
N_.fish Drop use of the N_ no-op for translation descriptions. Instead, tell xgettext that any token following '--description' should be translated. This should greatly speed up completion loading on platforms where fork() is slow. (Hi, OS X) 2007-01-16 11:18:28 +10:00
nextd-or-forward-word.fish Make the directory history keyboard shortcuts repaint the screen. Otherwise, the prompt won't reflect the new CWD. This is needed because of the reduced amounts of repainting done since 1.22.2 2006-12-15 04:23:13 +10:00
nextd.fish Make dirh, nextd, prevd work on OS X 2012-05-04 18:53:38 -07:00
open.fish Implement 'open' for Cygwin. 2013-08-13 17:21:40 +03:00
popd.fish Make all descriptions for function calls use the implicit translation from the previous patch instead of explicitly using N_ 2007-01-16 11:29:18 +10:00
prevd-or-backward-word.fish Make the directory history keyboard shortcuts repaint the screen. Otherwise, the prompt won't reflect the new CWD. This is needed because of the reduced amounts of repainting done since 1.22.2 2006-12-15 04:23:13 +10:00
prevd.fish Make dirh, nextd, prevd work on OS X 2012-05-04 18:53:38 -07:00
prompt_pwd.fish Fix some typos. 2013-09-12 11:46:31 +02:00
psub.fish use mktemp(1) to generate temporary file names 2014-04-28 10:42:00 +08:00
pushd.fish Make all descriptions for function calls use the implicit translation from the previous patch instead of explicitly using N_ 2007-01-16 11:29:18 +10:00
seq.fish 'seq' should return 1, not exit 1, on bad arglist 2014-02-16 01:17:12 -08:00
setenv.fish Make all descriptions for function calls use the implicit translation from the previous patch instead of explicitly using N_ 2007-01-16 11:29:18 +10:00
sgrep.fish call original grep in sgrep 2010-09-19 13:56:30 +08:00
trap.fish Make trap sort of work on OS X 2013-04-28 16:31:25 -07:00
type.fish Make type -a print all executables in PATH 2013-10-29 13:32:14 +08:00
umask.fish Fix umask function regex 2014-07-29 01:43:18 -04:00
up-or-search.fish Further work on keyboard navigating the completion list 2014-01-18 12:42:53 -08:00
vared.fish Force at least one line of output for set_color. 2014-03-03 22:17:55 +01:00