[Bash-completion-commits] [SCM] bash-completion branch, master, updated. 1cd950db89ad482af0af623a1c03f1f2dcd65676

David Paleino d.paleino at gmail.com
Fri Jun 5 06:36:35 UTC 2009


The following commit has been merged in the master branch:
commit 1cd950db89ad482af0af623a1c03f1f2dcd65676
Author: David Paleino <d.paleino at gmail.com>
Date:   Fri Jun 5 08:36:22 2009 +0200

    Split chsh completion to contrib/chsh

diff --git a/CHANGES b/CHANGES
index 7ecb63d..3e02e85 100644
--- a/CHANGES
+++ b/CHANGES
@@ -21,6 +21,7 @@ bash-completion (1.x)
   * Split autorpm completion to contrib/autorpm
   * Split jar completion to contrib/jar
   * Split chkconfig completion to contrib/chkconfig
+  * Split chsh completion to contrib/chsh
 
   [ Ville Skyttä ]
   * Split yum and yum-arch completion into contrib/yum.
diff --git a/Makefile.am b/Makefile.am
index 8524ea1..ea7600a 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -13,6 +13,7 @@ bashcomp_DATA = contrib/ant \
 		contrib/brctl \
 		contrib/bzip2 \
 		contrib/chkconfig \
+		contrib/chsh \
 		contrib/cfengine \
 		contrib/cksfv \
 		contrib/clisp \
diff --git a/bash_completion b/bash_completion
index 0b022e0..7af2630 100644
--- a/bash_completion
+++ b/bash_completion
@@ -2118,26 +2118,6 @@ _apt_build()
 } &&
 complete -F _apt_build $filenames apt-build
 
-# chsh(1) completion
-#
-_chsh()
-{
-	local cur prev
-
-	COMPREPLY=()
-	cur=`_get_cword`
-	prev=${COMP_WORDS[COMP_CWORD-1]}
-
-	if [ "$prev" = "-s" ]; then
-		_shells
-	else
-		COMPREPLY=( $( compgen -u -- $cur ) )
-	fi
-
-	return 0
-}
-complete -F _chsh chsh
-
 # This function provides simple user at host completion
 #
 _user_at_host() {
diff --git a/contrib/chsh b/contrib/chsh
new file mode 100644
index 0000000..46d728d
--- /dev/null
+++ b/contrib/chsh
@@ -0,0 +1,19 @@
+# chsh(1) completion
+#
+_chsh()
+{
+	local cur prev
+
+	COMPREPLY=()
+	cur=`_get_cword`
+	prev=${COMP_WORDS[COMP_CWORD-1]}
+
+	if [ "$prev" = "-s" ]; then
+		_shells
+	else
+		COMPREPLY=( $( compgen -u -- $cur ) )
+	fi
+
+	return 0
+}
+complete -F _chsh chsh

-- 
bash-completion



More information about the Bash-completion-commits mailing list