2896 Commits

Author SHA1 Message Date
Ville Skyttä
a7c3da6322 Take advantage of short-circuit eval of [[ ]]. 2011-04-04 23:57:07 +03:00
Ville Skyttä
0c08c5a009 Drop unnecessary $USERLAND check. 2011-04-04 23:52:56 +03:00
Ville Skyttä
94c51fc36e Coding style consistency tweaks. 2011-04-04 23:48:22 +03:00
Ville Skyttä
f7c93600a6 Avoid some have() calls.
Single file existence etc checks are cheaper than full $PATH lookups.
2011-04-04 22:12:40 +03:00
Ville Skyttä
c65949385a Drop unnecessary subshell. 2011-04-04 22:09:30 +03:00
Ville Skyttä
4d3e9d092c Add $_backup_glob for matching various backup files and reuse it.
Compared to the previous embedded/duplicated globs, this one
additionally treats *.orig and *.rej as backup files.
2011-04-01 20:22:10 +03:00
Ville Skyttä
ec25abac89 (testsuite) Make ri basic test case more likely to work.
Plain "ri " completion returns 3729 entries on my box which is way
more than fits into the expect buffer we have in effect.
2011-04-01 20:09:42 +03:00
Matej Cepl
e10848b7e5 Complete oo{writer,impress,calc,draw} on LibreOffice FlatXML extensions (RedHat: #692548). 2011-03-31 22:46:58 +03:00
Ville Skyttä
61b91cb41b Trivial code cleanup. 2011-03-29 23:29:51 +03:00
Ville Skyttä
c398b1c56f (testsuite) Fix get_hosts option docs. 2011-03-29 23:27:51 +03:00
Igor Murzov
10bd7d3d41 Correct options for pkgtool
Took options from pkgtool script itself. They are wrong in man page
2011-03-28 20:28:59 +04:00
Igor Murzov
e0e63f2518 Add --terse option to installpkg (added in pkgtools-13.37) 2011-03-28 20:24:00 +04:00
Igor Murzov
497ed2ce99 Replace hyphens with underscores in function names
It should fix:
/etc/bash_completion.d/slapt: line 69: `_slapt-get': not a valid identifier
Reported on LQ:
http://www.linuxquestions.org/questions/slackware-14/bash-completion-1-3-noarch-1-causes-xorg-failure-863157/
2011-03-28 20:20:02 +04:00
Freddy Vulto
68e9a8e6eb (testsuite) Add -unsorted option to _get_hosts()
_known_hosts_real tests were failing after commit 81794a9:

   FAIL: Hosts should be put in COMPREPLY
   FAIL: Hosts should have username prefix and colon suffix

This is because tcl's get_hosts() is now doing a unique sort, but bash
_known_hosts_real() IS returning duplicates relying on bash's compgen/complete
to remove the duplicates).  Fixed by calling _get_hosts -unsorted.
2011-03-27 23:12:14 +02:00
Freddy Vulto
7cd17ada11 Fix __reassemble_comp_words_by_ref() unquoted pattern removal
Commit 8227e76 was failing on these `chown' tests in bash-4.1:

    FAIL: Check preserve special chars in funky\ user:Debia<TAB>
    FAIL: Check preserve special chars in funky\.user:Debia<TAB>
    FAIL: Check preserve special chars in fu\ nky.user:Debia<TAB>
    FAIL: Check preserve special chars in f\ o\ o\.\bar:Debia<TAB>
    FAIL: Check preserve special chars in foo\_b\ a\.r\ :Debia<TAB>

because a removal pattern is expanded:

    $ a=\\b
    $ w=\\
    $ echo ${a#$w}    # Doesn't work
    \b
    $ echo ${a#"$w"}  # Ok
    b
2011-03-27 22:08:55 +02:00
David Paleino
8c3a0e94d1 Make $cur local 2011-03-27 13:58:59 +02:00
David Paleino
42b107bcfc Fix broken _allowed_groups usage (shadow and coreutils) 2011-03-27 12:40:44 +02:00
Ville Skyttä
a73774c833 Fix regressions and further tweak previous java completion patch.
Fix inner class regression, adapt test suite, turn off nospace for
single class completions, protect -o nospace for bash < 4.
2011-03-24 20:45:16 +02:00
Mattias Ulbrich
920b1f93b6 improved java completion
now suggests also package names
2011-03-24 20:44:10 +02:00
Freddy Vulto
8227e76e09 Improve __reassemble_comp_words_by_ref() (Alioth #313057)
Prohibit word creation of characters if they're excluded from
$COMP_WORDBREAKS.  For example, with ':' included in $COMP_WORDBREAKS,
'a b:' should split to 'b' and ':'.  With ':' excluded from
$COMP_WORDBREAKS, 'a b:' should split to 'b:', NOT 'b' and ':'.
2011-03-24 00:00:58 +01:00
Ville Skyttä
2c78ae3ea1 (testsuite) Add basic xzdec test case. 2011-03-21 19:46:13 +02:00
Ville Skyttä
70a3b8a8b4 xz* option completion updates. 2011-03-21 19:45:08 +02:00
Ville Skyttä
03fee4b4d3 Apply xz completion to pxz too. 2011-03-21 19:44:17 +02:00
Ville Skyttä
8aed79dd3e Avoid some unnecessary command invocations. 2011-03-21 19:23:57 +02:00
Ville Skyttä
f973eb043c More tar *[cr]*f completion improvements. 2011-03-20 18:43:12 +02:00
Ville Skyttä
0ae464e580 Improve tar *[cr]*f completions (Debian: #618734). 2011-03-20 18:22:21 +02:00
Ville Skyttä
4f4c7f2d1f Add bunch of tar option completions. 2011-03-20 18:05:54 +02:00
Ville Skyttä
87227ceccd Don't lose J if present in original tar command when finding out how to untar. 2011-03-20 17:21:02 +02:00
Ville Skyttä
91c13f0eed Fix completion of files inside *.tar.bz2 archives when [Ijy] is not given. 2011-03-20 17:12:52 +02:00
David Paleino
14fc9f2965 If _filedir 'ext' returns nothing, just fallback to generic file completion. Patch by Clint Byrum (Debian: #619014, LP: #533985) 2011-03-20 15:22:33 +01:00
Ville Skyttä
a6354b8107 Add reptyr completion. 2011-03-12 12:04:02 +02:00
Ville Skyttä
c60896e0e1 Add aspell --add-filter|--rem-filter completions. 2011-03-03 23:25:21 +02:00
Ville Skyttä
da2d63fb19 Get aspell --mode completions from 'aspell modes' output. 2011-03-03 23:24:21 +02:00
Guillaume Rousse
d21e05504a drop -o filenames, as suggested by Ville 2011-02-26 16:55:05 +01:00
Ville Skyttä
a34a380410 (testsuite) Add basic puppet test case. 2011-02-26 15:58:20 +02:00
Ville Skyttä
ab66ae79c2 (testsuite) Add basic mdadm test case. 2011-02-26 15:47:02 +02:00
Guillaume Rousse
a29ed87cd5 use simple quotes for constant strings 2011-02-23 21:42:08 +01:00
Guillaume Rousse
2e88c29991 Merge branch 'master' of git+ssh://git.debian.org/git/bash-completion/bash-completion 2011-02-23 21:39:30 +01:00
Guillaume Rousse
8916625769 rename special and subspecial variables for consistency with other similar completions, and avoid leaking 2011-02-23 21:36:10 +01:00
Guillaume Rousse
93ade30ce6 use known hosts completion with --server option 2011-02-23 21:31:37 +01:00
Guillaume Rousse
b7ef18dded no need to use a variable for a list used only once 2011-02-23 21:27:27 +01:00
Guillaume Rousse
d9c605b020 indentation fixes 2011-02-23 21:24:53 +01:00
Guillaume Rousse
4946872a85 wrap long lines 2011-02-23 21:22:18 +01:00
Guillaume Rousse
b0e7111397 use for subshell, instead of backquotes 2011-02-23 21:18:18 +01:00
Guillaume Rousse
dac9622e90 add puppet completion 2011-02-23 21:14:35 +01:00
Ville Skyttä
5c48e85a86 smartctl completion improvements. 2011-02-18 22:09:05 +02:00
Ville Skyttä
d852c18d41 Simplify rpmbuild --buildpolicy completion. 2011-02-13 18:54:54 +02:00
Ville Skyttä
34f574dc89 Add rpmbuild --buildpolicy completion. 2011-02-11 00:06:20 +02:00
Ville Skyttä
344076f92c Use numeric comparison operators when comparing numerically. 2011-02-10 23:55:16 +02:00
Ville Skyttä
6042cbe2f5 Split rpm and rpmbuild completions and improve them both.
The option sets are different, and rpm should not have been used to
build packages since rpm 4.0, and could not have been used for that
since rpm 4.1.
2011-02-10 23:51:26 +02:00