summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAaron Walker <ka0ttic@gentoo.org>2005-02-06 02:00:33 +0000
committerAaron Walker <ka0ttic@gentoo.org>2005-02-06 02:00:33 +0000
commit63cbca0fc00fd831709c04b0b7e418f41d353439 (patch)
tree0eeb0e168c1135c2ae23400f49dddf7f614beb6b /app-misc
parentstable on amd64 (diff)
downloadhistorical-63cbca0fc00fd831709c04b0b7e418f41d353439.tar.gz
historical-63cbca0fc00fd831709c04b0b7e418f41d353439.tar.bz2
historical-63cbca0fc00fd831709c04b0b7e418f41d353439.zip
Added figlet command-line completion; closes bug 80436.
Package-Manager: portage-2.0.51-r15
Diffstat (limited to 'app-misc')
-rw-r--r--app-misc/figlet/ChangeLog6
-rw-r--r--app-misc/figlet/Manifest17
-rw-r--r--app-misc/figlet/figlet-221-r1.ebuild5
-rw-r--r--app-misc/figlet/files/figlet.bashcomp52
4 files changed, 74 insertions, 6 deletions
diff --git a/app-misc/figlet/ChangeLog b/app-misc/figlet/ChangeLog
index 390e8cb47778..db696f2a21eb 100644
--- a/app-misc/figlet/ChangeLog
+++ b/app-misc/figlet/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for app-misc/figlet
# Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-misc/figlet/ChangeLog,v 1.14 2005/01/01 15:02:00 eradicator Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-misc/figlet/ChangeLog,v 1.15 2005/02/06 02:00:33 ka0ttic Exp $
+
+ 05 Feb 2005; Aaron Walker <ka0ttic@gentoo.org> +files/figlet.bashcomp,
+ figlet-221-r1.ebuild:
+ Added figlet command-line completion; closes bug 80436.
10 Jul 2004; Tom Martin <slarti@gentoo.org> figlet-221-r1.ebuild:
Marked ~amd64.
diff --git a/app-misc/figlet/Manifest b/app-misc/figlet/Manifest
index 95708e4445d1..7497e28b8e08 100644
--- a/app-misc/figlet/Manifest
+++ b/app-misc/figlet/Manifest
@@ -1,6 +1,17 @@
-MD5 748b087e01d7f4cbba49e5168e0f8cfc ChangeLog 2136
-MD5 90d4da98c9faa3660aca8250e502e0ba figlet-221-r1.ebuild 1551
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
+MD5 8f9c67bfc5973f978b668ce3e17750f0 figlet-221-r1.ebuild 1610
+MD5 6e374f50ddf585ce8ccfa72c742b8d6d ChangeLog 2289
MD5 27c80a8d690d932f131215d791821fcd metadata.xml 253
-MD5 3a2551bb3e1052d837bd6852df170706 files/digest-figlet-221-r1 203
MD5 e2d8534fe03c0cd75ce80993267a59f5 files/figlet-22-r1-gentoo.diff 1110
MD5 33b24c1ec85f5424d660e01f97d383a0 files/figlet-221-gentoo.diff 1029
+MD5 037d80f2223647ba31fce7b92f2cad73 files/figlet.bashcomp 1489
+MD5 3a2551bb3e1052d837bd6852df170706 files/digest-figlet-221-r1 203
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.0 (GNU/Linux)
+
+iD8DBQFCBXpKEZCkKN40op4RAlBaAKCTbCLb2gU2IWr9BYoMP4QjrpqC9ACZATu2
+0TxQaZ0yM3HvtHj1m8a79+0=
+=Lyyy
+-----END PGP SIGNATURE-----
diff --git a/app-misc/figlet/figlet-221-r1.ebuild b/app-misc/figlet/figlet-221-r1.ebuild
index 17db9875df74..b3ce7c6b7d25 100644
--- a/app-misc/figlet/figlet-221-r1.ebuild
+++ b/app-misc/figlet/figlet-221-r1.ebuild
@@ -1,8 +1,8 @@
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-misc/figlet/figlet-221-r1.ebuild,v 1.7 2005/01/01 15:02:00 eradicator Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-misc/figlet/figlet-221-r1.ebuild,v 1.8 2005/02/06 02:00:33 ka0ttic Exp $
-inherit eutils
+inherit eutils bash-completion
MY_P=${P/-/}
S=${WORKDIR}/${MY_P}
@@ -54,4 +54,5 @@ src_install() {
install || die "make install failed"
dodoc README figfont.txt || die "dodoc failed"
+ dobashcompletion ${FILESDIR}/figlet.bashcomp
}
diff --git a/app-misc/figlet/files/figlet.bashcomp b/app-misc/figlet/files/figlet.bashcomp
new file mode 100644
index 000000000000..6b7934d76c8a
--- /dev/null
+++ b/app-misc/figlet/files/figlet.bashcomp
@@ -0,0 +1,52 @@
+# Copyright 1999-2005 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-misc/figlet/files/figlet.bashcomp,v 1.1 2005/02/06 02:00:33 ka0ttic Exp $
+
+# bash command-line completion for figlet
+# author: Aaron Walker <ka0ttic@gentoo.org>
+
+_figlet() {
+ local cur prev opts x
+ COMPREPLY=()
+ cur="${COMP_WORDS[COMP_CWORD]}"
+ prev="${COMP_WORDS[COMP_CWORD-1]}"
+ opts="-f -d -c -l -r -x -t -w -p -n -D -E -C -N -s -S -k -W -o \
+ -m -v -I -L -R -X"
+
+ if [[ "${cur}" == -* || ${COMP_CWORD} -eq 1 ]] ; then
+ COMPREPLY=( $(compgen -W "${opts}" -- $cur) )
+ return 0
+ fi
+
+ case "${prev}" in
+ -f)
+ COMPREPLY=( $(compgen -f -- $cur) \
+ $(compgen -W "$(\
+ for x in /usr/share/figlet/*.flf ; do \
+ [[ -f ${x} ]] && { local y=${x##*/} ; echo ${y%.*} ; } \
+ done)" -- $cur) )
+ ;;
+ -d)
+ COMPREPLY=( $(compgen -d -S '/' -- $cur) )
+ ;;
+ -C)
+ COMPREPLY=( $(compgen -f -- $cur) \
+ $(compgen -W "$(\
+ for x in /usr/share/figlet/*.flc ; do \
+ [[ -f ${x} ]] && { local y=${x##*/} ; echo ${y%.*} ; } \
+ done)" -- $cur) )
+ ;;
+ -m)
+ COMPREPLY=( $(compgen -W "$(\
+ for ((x = 1 ; x < 64 ; x++)) ; do \
+ echo ${x} ; \
+ done)" ) )
+ ;;
+ -I)
+ COMPREPLY=( $(compgen -W "-1 0 1 2 3 4" -- $cur) )
+ ;;
+ esac
+}
+complete -o filenames -F _figlet figlet
+
+# vim: set ft=sh tw=80 sw=4 et :