1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
|
#compdef pdfgrep
# Zsh completion for pdfgrep.
# Copyright (C) 2017 by Hans-Peter Deifel (hpd@hpdeifel.de)
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the
# Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
# Boston, MA 02110-1301 USA.
_arguments -s -S -A "-*" \
"(-n --page-number)"{-n,--page-number}"[prefix match with page number]" \
"(-i --ignore-case)"{-i,--ignore-case}"[ignore case distinctions]" \
"(-F --fixed-strings -P --perl-regexp)"{-F,--fixed-strings}"[use literal strings]" \
"(-F --fixed-strings -P --perl-regexp)"{-P,--perl-regexp}"[use Perl compatible regular expression syntax]" \
"(-H --with-filename -h --no-filename)"{-H,--with-filename}"[print filename for each match]" \
"(-h --no-filename -H --with-filename)"{-h,--no-filename}"[don't print filename]" \
"(-c --count)"{-c,--count}"[print only a count of matches per file]" \
"(-p --page-count)"{-p,--page-count}"[count matches per page]" \
"(-C --context)"{-C,--context=}"[specify lines of context]:lines" \
"(-A --after-context)"{-A,--after-context=}"[specify lines of trailing context]:lines" \
"(-B --before-context)"{-B,--before-context=}"[specify lines of leading context]:lines" \
"--color=[use colors for highlighting]:color:(always never auto)" \
"--cache[use a cache for faster operation]" \
"(-r -R --recursive --dereference-recursive)"{-r,--recursive}"[search directories recursively]" \
"(-r -R --recursive --dereference-recursive)"{-R,--dereference-recursive}"[search directories recursively, follow symlinks]" \
"*--exclude=[skip files]:exclude" \
"*--include=[opposite of exclude]:include" \
"(- 1)--help[display help information]" \
"(- 1)"{-V,--version}"[display version information]" \
"(-q --quiet)"{-q,--quiet}"[suppress all normal output]" \
"(-Z --null)"{-Z,--null}"[replace colon after filename by null byte]" \
"--match-prefix-separator=[specify separator between filename, page and text]:separator" \
"*--password=[specify password to decrypt file]:password" \
"(-m --max-count)"{-m,--max-count=}"[process at most count matches]:count" \
"--debug[enable debug output]" \
"--warn-empty[warn if a PDF file contains no text]" \
"--unac[remove accents and ligatures]" \
'1: :_guard "^-*" pattern' \
'*:pdf file:_files -g "*.pdf(-.)"'
|