1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-09-20 03:51:07 +02:00
Commit graph

1370 commits

Author SHA1 Message Date
Jun T
d13c6dc441 32833: complete Python and Ruby arguments as for Perl 2014-07-03 22:55:42 +01:00
Jun T
c8e5be9d0f 32823: complete file instead of Perl script after - 2014-06-30 20:07:04 +01:00
Andrew Magee
605cc1ba57 19939: hg committable files 2014-06-06 21:51:17 +01:00
Barton E. Schaefer
f5ad1ccbd6 32653: complete files with the ".phar" extension as well as ".php"
Also respect the suffixes zstyle to change the extensions
2014-06-01 15:21:13 -07:00
Peter Stephenson
5554cf8244 users/18860: man -M overrides manpath 2014-05-29 21:39:02 +01:00
Sebastien Alaiwan
7b1b1dbb45 32562: updates for bzr completion 2014-04-23 16:18:01 +01:00
llua
fe40b9c2a3 complete zfs ... -o multiple times 2014-04-06 16:57:48 +01:00
Danek Duvall
4dfe62640a 32505: improved Solaris compatibility for pgrep completion 2014-03-28 20:24:16 +00:00
m0viefreak
cd2eb07a78 m0viefreak: users/18655,18657,18660: assorted auto-removable suffix fixes
Src/Zle/compresult.c, Src/Zle/zle_misc.c, Src/Zle/zle_refresh.c: fix
auto-removable suffix highlighting

Completion/Unix/Command/_git: fix compadd for auto-removable suffix in
_git_commit_ranges and _git_stash
2014-03-23 13:02:12 -07:00
Takeshi Banse
ab917d4a0e 32502: fix typo in argument list for git completio 2014-03-21 19:42:02 +00:00
Peter Stephenson
fd4ac0a8c2 unposted: in Perforce path completion complete depots after // 2014-03-20 09:35:18 +00:00
Kosuke Asami
89c2342dd8 32471: tidy up pgrep completion 2014-03-13 20:03:56 +00:00
Kosuke Asami
d91732acba 32471: handle BSD process management in pgrep completion 2014-03-13 20:02:53 +00:00
Kosuke Asami
de68b6bbf1 32472: new pgrep completion options 2014-03-13 20:01:15 +00:00
Peter Stephenson
f798f13b0e Fix merge conflict 2014-02-28 18:45:35 +00:00
Jun T
7d7242405a 32435: improved quoting for ignore-line completion style 2014-02-26 20:39:11 +00:00
Oliver Kiddle
079540cc78 users/18485: add .. as an auto-removable suffix in git revision ranges 2014-02-25 08:59:20 +01:00
Hong Xu
e5b55ebf45 Fix outdated npm completion 2014-02-24 09:32:01 +00:00
Sebastien Alaiwan
afe7ff6b5d 32642: improve bzr completion with directory path 2014-02-24 09:30:04 +00:00
m0viefreak
b97808fba2 32398: _git: completion updates up to latest git v1.9.0
- cherry-pick: allow commit ranges to be specified
- push: option is called --set-upstream and not --set-upstream-to
- status: offer -b,--branch when --porcelain or -z are given
  --porcelain and -z don't show the branch info by default, so it
  is needed to offer --branch for those options, too.
- checkout: add '--detach' option
- checkout: offer '-l' option when '--orphan' was given
- show-ref: update wording of --head and --heads according to man-page
- config: update default value for color.ui
  color-bool was changed to accept a default value as $parts[5]
- add support for 'cygstart' as a valid builtin browser on cygwin
- rebase: add suuport for --autostash and config.autostash
- update builtin browser list
- grep: add --{no,}textconv
- check-ignore: add --no-index
- update-ref: add --stdin -z
- add -C
- pull: add support for --rebase=preserve
- config: add support for http.*. options
- blame: -L can be given multiple times
- config: add support for http.savecookies
- push: add support for --force-with-lease
- diff: --diff-filter: allow lower-case variants (all-but ... specs)
- config: add support for 'fetch.prune' and 'remote.*.prune'
- check-ignore: -z: update message, check-attr: add -z
- config: add diff.orderfile
- revision options: add --exclude
- revision options: add --ignore-missing
- revision options: add --bisect
- rev-parse: add --stuck-long
- merge-base: add --fork-point
- config: implement submodule.*.update completion
- send-email: add --smtp-ssl-cert-path and config options
2014-02-18 12:22:21 +01:00
m0viefreak
f8e874ef9d 32397: _git: fix __git_submodules to only use the actual name of the submodule
The output of 'submodule status' is

Xsha1 name (describe)

X being one of -,+,U,[space]

We are only interested in the name part and not the whole line.

Fix the parameter expansions accordingly.
2014-02-18 12:22:21 +01:00
m0viefreak
139ee0e351 32395: _git: diff: refactor and fix wrong completions
Before this, there were several cases where the completion
would offer the wrong things:

$ git diff branch -- <tab>

would try to complete "changed in workdir files", but needs to
complete all "tree files in HEAD".

$ git diff --cached -- file1 file2 <tab>
would try to complete "changed in workdir files" but needs to
complete "changed in index files".

...

After this change all possible combinations are taken into
account and completion should work properly.
2014-02-18 12:22:16 +01:00
m0viefreak
946a99a0b3 32396: _git: fix __git_committish_range_{first,last} and __git_is_committish_range
- Ranges with 3 dots would always fail, because the non-greedy
  expansion  %..(.|)* in __git_committish_range_first would only
  remove '..' and never three dots. 'a...b' would end up in 'a.'.
  Use ${${1%..*}%.} instead.
- Use a similar approach for __git_committish_range_last.
- Wrap them in another expansion to replace empty results with 'HEAD'.
  Git man-page states omitted range ending are being replaced with
  HEAD. This rule has to be followed to make completions like
  'git log foo.. -- <tab>' work properly.
- Add an additional check to make sure none of the extracted first/last
  parts contain additional '..' in invalied ranges such as 'a..b..c'.
  This gets rid of the 'TODO:' and ideally saves a few unneded
  calls to git rev-parse.
2014-02-18 12:19:23 +01:00
Jun T
1531d0463c 32300: new od completion 2014-01-30 15:53:47 +00:00
Christian Hesse
0ab7834a15 32316: complete new ssh key type 2014-01-29 09:24:54 +00:00
Barton E. Schaefer
a2098b0b26 users/18368: compromise to restore partial path completion inadvertently removed by 31159 2014-01-27 21:54:13 -08:00
Peter Stephenson
ff74ffb0f3 32255: complet for python under some pythonN.M names 2014-01-14 15:44:49 +00:00
Koen Wilde
8fd6d5766c 32245: complete more mpc arguments 2014-01-10 22:26:30 +00:00
Mark Oteiza
3267b454d8 32238: suppress error output completing after ip 2014-01-07 19:25:32 +00:00
Jun T
ff650ada05 32231: _chmod was confused by options before the mode 2014-01-05 18:04:15 +00:00
Danek Duvall
ef2eaf1f78 32261: completion updates for Solaris 11, Update 1 2014-01-02 22:26:04 +00:00
Jun T
82cf0f5940 32056: Handle completion for different versions of iconv 2013-12-09 10:31:49 +00:00
Hong Xu
567b494033 32069: completion for "git submodule update --remote" 2013-11-30 12:46:19 -08:00
Peter Stephenson
4163ebf4c7 unposted, see 32054: Rationalise character encoding.
Shell functions are strictly ASCII for maximum portability.

Other files within the distribution may contain UTF-8 characters.

Exception for test files: where they need single character input
with the top bit set, ISO-8859-X is used (X doesn't matter as
we don't need the Euro).
2013-11-27 15:56:44 +00:00
Peter Stephenson
7423ac14e5 unposted, see 32050, 32051: remove non-ASCII characters in functions 2013-11-25 16:11:10 +00:00
Peter Stephenson
412116e02b unposted: Prepare 5.0.2-test-2. 2013-11-25 11:07:47 +00:00
Jun T
42fabadc35 31984: new df completion 2013-11-14 15:10:57 +00:00
Jun T
973f8491ed 31909: new cat completion 2013-10-27 16:38:24 +00:00
Øystein Walle
95a5ca90d9 31865: _git: Make --batch(-check) accept an argument
Also reword the explanation slightly to make it more compact since more
explanation is needed.
2013-10-21 17:40:13 +02:00
Øystein Walle
3d77fa789d 31864: _git: Add two sub-comamnds introduced in v1.8.4
Add _git-check-ignore() and _git-check-mailmap()
2013-10-21 17:40:12 +02:00
Øystein Walle
32ffba1214 31866: _git: Reword --heads to match new meaning 2013-10-21 17:40:09 +02:00
Øystein Walle
baee0a2295 31862: _git: Add status.short and status.branch 2013-10-21 17:40:07 +02:00
Øystein Walle
805b665901 31863: _git: Add new arguments introduced in Git v1.8.4 2013-10-21 17:40:03 +02:00
Øystein Walle
e91d90125b 31861: _git: Add git-clean -i/--interactive support
- Add -i and --interactive to _git-clean()
 - Add column.clean configuration variable
2013-10-21 17:40:01 +02:00
m0viefreak
7a37568b8c 31855: _git: revert: add '-e,--edit' 2013-10-21 17:39:59 +02:00
m0viefreak
2c1affc6c1 31856: _git: fix a few "undocumented" options
commit: '--null' is documented
relink: '-h,--help' are never documented for subcommands but always exist
verify-tag: '-v,--verbose' are documented with updated description
diff: '--cumulative' is deprecated -> remove
2013-10-21 17:39:57 +02:00
Øystein Walle
07ca60acf4 31858: _git: fix wrong default value 2013-10-21 17:39:56 +02:00
m0viefreak
80cb8e947f 31857: _git: Remove unsupported -q option from diff options 2013-10-21 17:39:53 +02:00
Øystein Walle
5585b95f3c 31859: _git: re-order the last two git-blame arguments
The proper syntax is git blame [<commit>] <file> where <commit> is optional.
2013-10-21 17:39:50 +02:00
Øystein Walle
7872a5becd 31854: _git: Make git-show accept diff arguments 2013-10-21 17:39:48 +02:00
Øystein Walle
34ba14e1ec 31853: _git: Add missing column.* config variables 2013-10-21 17:39:46 +02:00
Barton E. Schaefer
87c482d751 31840: "read" needs IFS unset to avoid stripping whitespace in makefiles 2013-10-18 08:35:22 -07:00
Barton E. Schaefer
d5ba3ed245 31818: fix completion for zsh in _sh, and document the _arguments behavior that made the fix necessary
To avoid side effects, reposition the _arguments call in _sh for the zsh
special case. Document the side effects so avoided, and clean up the
_arguments documentation a bit along the way.
2013-10-12 09:19:24 -07:00
Wayne Davison
7e4fd18519 Add new options for rsync 3.1.0. 2013-10-06 16:53:21 -07:00
m0viefreak
8a70a98577 31754: _git: git rm: make git rm --cached work as intended
While limiting the completion to __git_changed-in-index_files
makes perfect sense for "git diff", it is wrong to use for
"git rm", because it prevents it from completing files present in
HEAD. Giving --cached to git rm is supposed to
"just remove it from the index, keep the working tree copy"
and is in no way related to the file needing to be
modified in the index in the first place.
2013-09-22 14:01:16 +02:00
Øystein Walle
2025b05bcf 31752: _git: change completion text for consistency 2013-09-22 14:01:15 +02:00
m0viefreak
128de883bd 31753: _git: correct some "undocumented" options
diff options:
  --cumulative is deprecated --> remove
  -G / -S: reword -S to emphase the difference to -G

revision options:
  --abbrev: reword, to emphase the --abbrev-commit requirement
2013-09-22 14:01:15 +02:00
Øystein Walle
cf0eae5d96 31751: _git: remove TODOs of actually documented options
No functional changes.
2013-09-22 14:01:14 +02:00
Øystein Walle
ab05a3d6d4 31749: _git: fix some typos in description texts 2013-09-22 14:01:13 +02:00
m0viefreak
735e7becb9 31748: _git: support completing remote branches without <remote>/ prefix
this is used in git 1.8's
git checkout <branch>
as a shorthand for
git checkout -b <branch> --track <remote>/<branch>
in case <branch> exists on exactly one remote and is not a local branch
2013-09-22 14:01:12 +02:00
m0viefreak
e45f685d4a 31746: _git: reword _git-config TODO
Support for merge drivers, filter drivers, and diff drivers is
missing.
2013-09-22 14:01:12 +02:00
Øystein Walle
5ec6a1510a 31750: _git: add new configuration options to match latest git v1.8.3 2013-09-22 14:01:11 +02:00
Øystein Walle
6c4c11929c 31747: _git: completion updates to match latest git v1.8.3 part 2 2013-09-22 14:01:10 +02:00
m0viefreak
f20ba1a51e 31755: _git: completion updates to match latest git v1.8.3 2013-09-22 14:01:09 +02:00
m0viefreak
06d58592ab 31745: _git: correctly use __git_guard_number in some cases
The space is relevant to make the help text work as intended.
2013-09-22 14:01:08 +02:00
m0viefreak
ef4157fac4 31744: _git: make git submodule <cmd> completion work
The -A parameter in the main completion stopped completion
in the subcommands from working. Remove it.
2013-09-22 14:01:08 +02:00
m0viefreak
2813d8aa98 31743: _git: fix usage of ->int: for some entries in _git-config 2013-09-22 14:01:07 +02:00
m0viefreak
5f427b8245 31741: _git: fix a wrong variable in __git_config_values
This probably was a copy/paste mistake.
2013-09-22 14:01:06 +02:00
Luka Perkov
075ad840d6 31726: _git: add few more arguments for cherry-pick and revert
Signed-off-by: Luka Perkov <luka@openwrt.org>
2013-09-14 11:21:34 +02:00
Luka Perkov
99e3aa58da 31723: _systemd: add more system commands
While at it move suspend command so the order of the
sytem commands equals the one in the systemd help.

Signed-off-by: Luka Perkov <luka@openwrt.org>
2013-09-14 11:21:34 +02:00
Luka Perkov
c721356646 31708: _git: add --fixup and --squash options to commit
Signed-off-by: Luka Perkov <luka@openwrt.org>
2013-09-07 10:09:11 +02:00
Luka Perkov
a4245da999 31702: check for git rebase -i for autosquash 2013-09-06 21:48:00 +01:00
Peter Stephenson
1a4730b8ee based on 31641, 31642: completion for more make variants 2013-08-29 10:46:52 +01:00
Jun T
c5d9abc6c8 31756: further make completion improvements.
ake care of mutually exclusive options.
Add _description using $state_descr.
Add completions for --debug=flag.
Fix typo (pointed out by Daniel Shahaf).
2013-07-25 09:47:47 +01:00
Richard Hartmann
f9851d817f 31571: Completion/Unix/Command/_vcsh: Update 2013-07-24 22:03:55 +02:00
Eric Cook
4e3f838269 31558: name of qemu executable changed in completion. 2013-07-22 19:03:54 +01:00
Peter Stephenson
9a192dddd2 c.f. 31531: complete xcf files for image manipulation packages 2013-07-19 19:30:27 +01:00
Jun T
29256a7c96 31525: Fix some options in _make 2013-07-17 19:27:20 +01:00
Nick Cross
a71b8df9b2 Update make completion with gnu options 2013-07-12 09:37:36 +01:00
Peter Stephenson
7e17ea8016 users/17856: rewrite _make to use _arguments.
No new option handling yet, but this should make it easier to add.
2013-07-11 11:14:38 +01:00
Peter Stephenson
95c044372a 31433: zcat -f doesn't need suffix .gz 2013-05-29 19:21:34 +01:00
Peter Stephenson
aa7467b0bf Improve Perforce jobs completion to limit
potentially huge output using jobview by default;
fix quoting of arguments passed on to eval within _call_program.
2013-05-14 14:25:14 +01:00
Jun T
cbf6f144a9 31357: _cp: add support for Mac OS X
If not GNU nor darwin, assume POSIX.
2013-04-29 17:11:05 +02:00
Peter Stephenson
8ab3a7b0e6 31356: typo in new _comp_locale noted by Bart 2013-04-29 15:07:30 +01:00
Peter Stephenson
8cdb57b3b7 31355: _comp_locale tries to sanitise locales but keep CTYPE;
use this for subversion completion.
2013-04-29 10:08:07 +01:00
Ramkumar Ramachandra
2ea9cd4775 31288: _git: fix shortlog completer
Currently, __git-shortlog () says that 'git shortlog' can only accept
commits as arguments (probably because the official documentation says
this).  This is entirely untrue: shortlog can accept
commit-range-or-file, just like log can.  Fix the completer by copying
out segments from the __git-log () function.

Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
2013-04-25 14:36:08 +02:00
Ramkumar Ramachandra
cbdedcfbfe 31289: _git: branch.*.pushremote, remote.pushdefault
The configuration variables branch.*.pushremote and remote.pushdefault
are relatively new, and are currently not completed by ZSH.  Fix this.

Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
2013-04-21 12:12:44 +02:00
Ramkumar Ramachandra
d1a3075293 31286: _git: add a couple of browsers
Add google-chrome/chromium to the list of builtinbrowsers in
__git_browsers ().

Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
2013-04-21 12:12:43 +02:00
Torstein Hegge
cc7437bf2f 31159: git: Pass prefix filter to ls-files even if it matches no files
When a branch or tag name is completed with zsh in a large git repo, the
completion is slow if the given prefix doesn't match a file or directory in
the current working directory. Testing with linux.git, which contains release
tags like v3.9 and a directory virt/:

  git log v<tab>

takes about 0.5 seconds, while

  git log v3<tab>

takes about 25 seconds.

(Timed using zsh 4.3.17, on a fairly slow cpu. zsh from git appears to be
quite a bit faster, but the difference between completing v and v3 is still
large.)

The difference between the two is that v<tab> passes the result of v* to git
ls-files while v3<tab> determines that v3* matches no files, and passes an
empty prefix to git ls-files. So git ls-files lists all files in the repo
and passes that on to _multi_parts.

Making git do the expansion of the * after the prefix lets git ls-files v3*
return an empty list, making _multi_parts job easier.

This does not affect the behavior of git log <tab>, but improves the
performance of partial tag and branch tab-completion in the common case where
file names and tag/branch names don't overlap.
2013-04-20 22:29:02 +02:00
Jun T
452aa5157a 31281: _du: add support for Mac OS X 2013-04-20 11:56:04 +02:00
Peter Stephenson
7514fe4a66 Daniel Friesel: 31265: improved option handling for devtodo. 2013-04-16 09:46:46 +01:00
Peter Stephenson
18bba82101 unposted: fix some .distfiles which mention files that have gone 2013-04-08 20:23:42 +01:00
Frank Terbeck
abb32da0e7 31221: Handle zero defined aliases better 2013-04-05 20:19:33 +02:00
Peter Stephenson
0c32aa6274 31203: add new etags completion. 2013-04-04 16:02:52 +01:00
Mikael Magnusson
7c50da8394 31182: _awk: Allow sticked arguments 2013-03-29 09:46:18 +00:00
Peter Stephenson
275ba0fdca Han Pingtian: 31167 (with tweak): limit use of colons for recognising
remote path in ssh completion
2013-03-20 20:33:45 +00:00
Mikael Magnusson
ba88c42a5b 30490: _java: -keystore takes a file argument, so complete files 2013-03-10 12:38:18 +00:00
Oliver Kiddle
ac22eab0d9 31077: update for new options in GNU sort 2013-02-27 22:17:29 +00:00
Oliver Kiddle
c2e00298c2 c.f. 31071: remove duplicate _osc and rename _ps to avoid name clash 2013-02-27 21:43:15 +00:00
Oliver Kiddle
a409dbf74c 31058: add completion of options from newer versions of some commands 2013-02-21 10:49:22 +00:00