File: README.ZSH

package info (click to toggle)
feta 1.4.15
  • links: PTS
  • area: main
  • in suites: etch-m68k
  • size: 444 kB
  • ctags: 85
  • sloc: perl: 1,200; sh: 192; makefile: 55
file content (18 lines) | stat: -rw-r--r-- 683 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
For users of the ZSH shell:
---------------------------
It it possible to use Feta and APT to autocomplete commands. To do that, add
the following lines to your ~/.zlogin or ~/.zshrc:

compctl -D -f + -UQ -K multicomp
fetacmds=(`feta commands`)
pkgnames=(`/usr/bin/apt-cache pkgnames`)
compctl -x 'p[1]' -k fetacmds - 'p[2,-1]' -k pkgnames + -g '*.deb' + -g '/' + -f -- feta

Now, type 'feta '<tab>, and you should get a list of commands you can
autocomplete. Typing tab again will let you see a list of packages, which
you can also autocomplete.

The downside is that this can be pretty slow, and affect shell startup
time.

Thanks to Brett Smith for help with ZSH's compctl stuff.