From 591939ead3ae16cceb0cf7f39f6845d34b34e713 Mon Sep 17 00:00:00 2001 From: ianmacd <> Date: Wed, 20 Feb 2002 05:26:08 +0000 Subject: [PATCH] _longopt(): add irb to list of commands _longopt(): refine sed command that filters long options --- bash_completion | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bash_completion b/bash_completion index 259e3b09..792c3808 100644 --- a/bash_completion +++ b/bash_completion @@ -1,6 +1,6 @@ # bash_completion - some programmable completion functions for bash 2.05a # -# $Id: bash_completion,v 1.136 2002/02/20 03:56:08 ianmacd Exp $ +# $Id: bash_completion,v 1.137 2002/02/20 06:26:08 ianmacd Exp $ # # Copyright (C) Ian Macdonald # @@ -1758,7 +1758,7 @@ _longopt() if [[ "$cur" == -* ]]; then COMPREPLY=( $( $1 --help | sed -e '/--/!d' \ - -e 's/.*--\([^ ]*\).*/--\1/' | \ + -e 's/.*\(--[-A-Za-z0-9]\+=\?\).*/\1/' | \ grep ^$cur | sort -u ) ) else _filedir @@ -1772,7 +1772,7 @@ for i in a2ps autoconf automake bc gprof ld nm objcopy objdump readelf strip \ touch vdir xargs awk gperf grep gpg grub indent less m4 sed shar date \ env seq su tee uname who texindex cat csplit cut expand fmt fold head \ md5sum nl od paste pr ptx sha1sum sort split tac tail tr unexpand \ - uniq wc units wget rsync ldd bash id info; do + uniq wc units wget rsync ldd bash id info irb; do have $i && complete -F _longopt -o filenames $i done unset i