forked from mirrors/nixpkgs
some fixes for bash completion (git, darcs) (-> etc/bash_completion.d/*)
svn path=/nixpkgs/trunk/; revision=12538
This commit is contained in:
parent
5030b79f44
commit
8302b6ba69
|
@ -0,0 +1,19 @@
|
|||
diff --git a/darcs-2.0.0/tools/darcs_completion b/darcs-2.0.0/tools/darcs_completion
|
||||
index 10628db..e36476e 100644
|
||||
--- a/tools/darcs_completion
|
||||
+++ b/tools/darcs_completion
|
||||
@@ -3,7 +3,6 @@
|
||||
# darcs command line completion.
|
||||
# Copyright 2002 "David Roundy" <droundy@abridgegame.org>
|
||||
#
|
||||
-have darcs &&
|
||||
_darcs()
|
||||
{
|
||||
local cur
|
||||
@@ -48,5 +47,5 @@ _darcs()
|
||||
return 0
|
||||
|
||||
}
|
||||
-[ "$have" ] && complete -F _darcs -o default darcs
|
||||
+complete -F _darcs -o default darcs
|
||||
|
|
@ -13,4 +13,6 @@ stdenv.mkDerivation {
|
|||
meta = {
|
||||
description = "Patch-based version management system";
|
||||
};
|
||||
|
||||
patches = ./bash-completion.patch; # I didn't have "have"
|
||||
}
|
||||
|
|
|
@ -76,7 +76,12 @@ stdenv.mkDerivation rec {
|
|||
|
||||
+ ''# Wrap `git-clone'
|
||||
wrapProgram $out/bin/git-clone \
|
||||
--prefix PATH : "${cpio}/bin" '';
|
||||
--prefix PATH : "${cpio}/bin" ''
|
||||
|
||||
+ ''# install bash completion script
|
||||
d="$out/etc/bash_completion.d"
|
||||
ensureDir $d; cp contrib/completion/git-completion.bash "$d"
|
||||
'';
|
||||
|
||||
meta = {
|
||||
license = "GPLv2";
|
||||
|
|
|
@ -74,6 +74,11 @@ stdenv.mkDerivation rec {
|
|||
for b in $out/bin/{git,gitk}; do
|
||||
[ -f "$b" ] && eval "wrapProgram $b $wrapArgs"
|
||||
done
|
||||
''
|
||||
|
||||
+ ''# install bash completion script
|
||||
d="$out/etc/bash_completion.d"
|
||||
ensureDir $d; cp contrib/completion/git-completion.bash "$d"
|
||||
'';
|
||||
|
||||
meta = {
|
||||
|
|
|
@ -11,9 +11,11 @@ args.stdenv.mkDerivation {
|
|||
|
||||
buildPhase = "true";
|
||||
|
||||
installPhase = "
|
||||
installPhase = ''
|
||||
python ./setup.py install --prefix=$out
|
||||
";
|
||||
d="$out/etc/bash_completion.d"
|
||||
ensureDir $d; ln -s "$out/share/stgit/contrib/stgit-completion.bash" "$d"
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "quilt for git (stacking patches)";
|
||||
|
|
Loading…
Reference in a new issue