2019 Commits

Author SHA1 Message Date
Ville Skyttä
329890a73b Extract scp local/remote file treatment into functions, reuse them in rsync. 2009-12-25 12:30:01 +02:00
Ville Skyttä
878b9a3e99 Define _tightvncviewer also when (only) vncviewer is available. 2009-12-25 12:14:10 +02:00
Ville Skyttä
cffa2db149 Fix comment spelling and line wrapping. 2009-12-25 12:07:47 +02:00
Ville Skyttä
8ab6708302 Drop dead code.
Availability of vncviewer is already checked with "have".
2009-12-25 12:05:44 +02:00
Ville Skyttä
894c877827 Add scp option completion. 2009-12-25 11:57:33 +02:00
Ville Skyttä
e0acaf8ed2 Split sshfs from contrib/ssh to contrib/sshfs. 2009-12-24 16:18:27 +02:00
Ville Skyttä
e308b07526 Add ssh -o BindAddress suboption completion. 2009-12-24 16:00:34 +02:00
Ville Skyttä
7c4de4a3ca Use the usual (local) $prev and $cur in _ssh_suboption. 2009-12-24 15:57:43 +02:00
Ville Skyttä
b56e45eaac Eliminate some duplicate code. 2009-12-24 15:52:05 +02:00
Leonard Crestez
92e7b73564 Improve ssh -o suboption completion (Alioth: #312122). 2009-12-24 15:45:19 +02:00
Ville Skyttä
8f56de625e Fix $2 example in _get_cword doc. 2009-12-24 15:31:19 +02:00
Freddy Vulto
c9c98da36e Fixed `quote_readline'.
This fixes completing filenames containing single quote (') on bash-4.

Also added emulation of `-o filenames' to _filedir.

Added tests for _filedir.

Fixed array assignment within __reassemble_comp_words_by_ref().
2009-12-24 10:00:29 +01:00
Freddy Vulto
f9db6abdc1 (testsuite) Added shell script `run'
This allows tab-completion of test scripts to run, e.g.:

    $ ./run unit/comp<TAB>
    $ ./run unit/compgen.exp

Instead of the old way:

    $ ./runUnit compgen.exp
2009-12-24 09:43:24 +01:00
Freddy Vulto
fec41f3c74 (testsuite) Added function `assert_bash_list_dir' 2009-12-24 09:41:22 +01:00
Jeremie Lasalle Ratelle
e2e1c391ed Fix rsync remote path completion (Alioth: #312173). 2009-12-23 16:18:32 +02:00
Ville Skyttä
ed45c2caaf Sync rsync options with rsync 3.0.6, add --compress-level arg completion. 2009-12-22 20:53:30 +02:00
Ville Skyttä
af90e1d5ad Indentation fixes. 2009-12-22 20:37:53 +02:00
Ville Skyttä
3d9f8206e1 Use awk more to reduce number of invoked commands a bit. 2009-12-21 23:00:31 +02:00
Ville Skyttä
6807b5e72d Replace some echos with printfs. 2009-12-21 00:09:02 +02:00
Ville Skyttä
c755d7becc Replace some uses of ls with printf. 2009-12-20 23:44:33 +02:00
Ville Skyttä
40a83563fd Add echo/printf and command/builtin considerations. 2009-12-15 23:51:48 +02:00
Ville Skyttä
8caddc47cf Protect grep invocations from user aliases (Alioth: 312143). 2009-12-15 23:48:10 +02:00
Ville Skyttä
247ada3cc4 Make k3b option vs filename completion work more like others. 2009-12-15 23:16:31 +02:00
Ville Skyttä
3de141dd76 Get rid of use of unportable -r argument to sed. 2009-12-15 23:09:32 +02:00
Ville Skyttä
5d691d4826 Complete aliases also when there are no known hosts files (RedHat: #546905). 2009-12-13 11:41:55 +02:00
Ville Skyttä
a358902e90 Include avahi host completions in known hosts completions no matter if we have known hosts or ssh config files or not. 2009-12-13 11:33:54 +02:00
Ville Skyttä
b72a0f6e26 Get rid of one unnecessary local variable. 2009-12-13 11:31:06 +02:00
Ville Skyttä
798bd2328e Doc and line wrapping fixes. 2009-12-13 11:28:14 +02:00
Freddy Vulto
359d242a49 (testsuite) Unset COMP_ variables at setup()
The COMP_ settings of the last test of _count_args() were falling through to
the first test of _get_cword(), causing it to fail.

Unset COMP_ variables within the unit tests setup & teardown.

Fixed last test at `_count_args.exp' by solving conflicting settings of
COMP_CWORD and COMP_POINT.

Steps to reproduce the problem:

    $ ./runUnit _count_args.exp _get_cword.exp
    ...
    Running ./unit/_count_args.exp ...
    Running ./unit/_get_cword.exp ...
    ERROR Unexpected output from bash command "_get_cword should run without errors":
    bash: $index: substring expression < 0
    ...
2009-12-12 12:36:38 +01:00
Freddy Vulto
736fa43e9f (testsuite) Fix comment 2009-12-12 12:08:07 +01:00
David Paleino
bf1d64153f Added .fdf completion to okular and evince 2009-12-11 17:49:23 +01:00
Ville Skyttä
733811a7b1 Don't append space after colon in _usergroup (bash 4 only). 2009-12-11 00:39:59 +02:00
Ville Skyttä
8f68300a0d Add wordbreak filtering to _count_args. 2009-12-11 00:14:54 +02:00
Ville Skyttä
b8ffa2dc48 Add some unit tests for _count_args. 2009-12-11 00:14:02 +02:00
Ville Skyttä
d1da93448f Comment spelling fixes. 2009-12-10 23:53:22 +02:00
Freddy Vulto
0529d738d2 Fix perl completion by removing : from wordbreaks
Specify colon (:) to be excluded as word separator character when doing
_get_cword().
2009-12-10 21:35:53 +01:00
Freddy Vulto
bc9e37a39c Merge branch 'master' of git+ssh://fvu-guest@git.debian.org/git/bash-completion/bash-completion 2009-12-10 21:29:48 +01:00
Freddy Vulto
b1e58b1a0e Fix __reassemble_comp_words_by_ref()
If a word is made up of multiple word separator characters:

   $ a b::<TAB>  # CWORDS are: a, b, and :: (correct)

__reassemble_comp_words_by_ref() couldn't handle this.  It assumed CWORDS were:

   $ a b::<TAB>  # CWORDS: a, b, : and : (but they're not)

Added test case for this.  To run the automated tests:

   ./runUnit _get_cword.exp
2009-12-10 21:28:24 +01:00
Ville Skyttä
69aa25cd8f Add pm-utils completion. 2009-12-10 22:00:52 +02:00
Ville Skyttä
0f25d9c66f Use sort -u instead of sort | uniq where appropriate. 2009-12-09 23:55:45 +02:00
Freddy Vulto
cbf7e1f963 Merge branch 'master' of git+ssh://fvu-guest@git.debian.org/git/bash-completion/bash-completion 2009-12-09 22:17:02 +01:00
Freddy Vulto
6fe53ef0e6 Fixed completing perl modules containing colons
The solution for bash-4 is to remove the colon from COMP_WORDBREAKS:

   COMP_WORDBREAKS=${COMP_WORDBREAKS//:}

The workaround for bash-3, or bash-4 with a colon in COMP_WORDBREAKS,
is to call:

  __ltrim_colon_completions "$cur"

after completions have been put in COMPREPLY.

See also: E13) Why does filename completion misbehave if a colon appears
in the filename? - Bash FAQ, http://tiswww.case.edu/php/chet/bash/FAQ
2009-12-09 22:13:56 +01:00
Ville Skyttä
98d439ea46 Use grep -E instead of deprecated egrep. 2009-12-09 22:52:00 +02:00
Ville Skyttä
04b7883f7d Use here strings instead of echos where appropriate (part of Alioth: #312143). 2009-12-09 22:46:09 +02:00
Ville Skyttä
09045a63b6 Add update-alternatives --set, --usage, and --slave completions, simplify some bits. 2009-12-09 21:26:12 +02:00
Ville Skyttä
d68c8e508a Indentation fixes. 2009-12-09 21:06:35 +02:00
Ville Skyttä
b4b4b37b96 Fix version in upstream availability comment. 2009-12-09 20:43:21 +02:00
Ville Skyttä
536a780c2e Drop short options from screen completions where long(er) ones exist, add --help and --version. 2009-12-09 01:06:47 +02:00
Ville Skyttä
21d0f70cb0 Use _shells in screen -s. 2009-12-09 01:01:49 +02:00
Ville Skyttä
6e2b17c4e6 Add deprecation status/reason comments. 2009-12-08 19:46:19 +02:00