git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #19046 from rycee/bump/bash-completion

Bump bash completion to 2.4

commit7c7e88b45e137d2f0458bae167ede9d5fe551df2 authorPeter Simons <simons@cryp.to> dateWed 28 Sep 2016, 18:39 (10 years ago) parentc166675e8817a2
9 files changed+20−48
nixos/modules/programs/bash/bash.nix+1−1 pkgs/shells/bash-completion/bash-4.3.patch−22 pkgs/shells/bash-completion/default.nix+9−16 pkgs/tools/audio/beets/default.nix+2−2 pkgs/tools/misc/colord/default.nix+2−2 pkgs/tools/package-management/createrepo_c/default.nix+2−2 pkgs/tools/package-management/packagekit/default.nix+2−2 pkgs/top-level/aliases.nix+1 pkgs/top-level/all-packages.nix+1−1
nixos/modules/programs/bash/bash.nix+1−1
@@ -16,7 +16,7 @@ let
1616 # programmable completion. If we do, enable all modules installed in
1717 # the system (and user profile).
1818 if shopt -q progcomp &>/dev/null; then
19− . "${pkgs.bashCompletion}/etc/profile.d/bash_completion.sh"
19+ . "${pkgs.bash-completion}/etc/profile.d/bash_completion.sh"
2020 nullglobStatus=$(shopt -p nullglob)
2121 shopt -s nullglob
2222 for p in $NIX_PROFILES; do
pkgs/shells/bash-completion/bash-4.3.patchdeleted−22
@@ -1,22 +0,0 @@
1−commit a9c556ccad819869a6a5d932aac0a75a99372f08
2−Author: Barry Warsaw <barry@python.org>
3−Date: Wed Sep 17 19:32:43 2014 +0300
4−
5− _init_completion: Handle cword < 0 (LP: #1289597)
6−
7− Previously only bash 4.3 seemed to provoke this, but now with the
8− empty command consistency tweak it occurs with earlier as well.
9−
10−diff --git a/bash_completion b/bash_completion
11−index 7e01ae4..3bb4bc2 100644
12−--- a/bash_completion
13−+++ b/bash_completion
14−@@ -727,7 +727,7 @@ _init_completion()
15− fi
16− done
17−
18−- [[ $cword -eq 0 ]] && return 1
19−+ [[ $cword -le 0 ]] && return 1
20− prev=${words[cword-1]}
21−
22− [[ ${split-} ]] && _split_longopt && split=true
pkgs/shells/bash-completion/default.nix+9−16
@@ -1,28 +1,21 @@
11{ stdenv, fetchurl }:
22
33stdenv.mkDerivation rec {
4− name = "bash-completion-2.1";
4+ name = "bash-completion-${version}";
5+ version = "2.4";
56
67 src = fetchurl {
7− url = "http://bash-completion.alioth.debian.org/files/${name}.tar.bz2";
8− sha256 = "0kxf8s5bw7y50x0ksb77d3kv0dwadixhybl818w27y6mlw26hq1b";
8+ url = "https://github.com/scop/bash-completion/releases/download/${version}/${name}.tar.xz";
9+ sha256 = "1xlhd09sb2w3bw8qaypxgkr0782w082mcbx8zf7yzjgy0996pxy0";
910 };
1011
11− patches = [ ./bash-4.3.patch ];
12−
1312 doCheck = true;
1413
15− # nmcli is included in the network-manager package
16− postInstall = ''
17− rm $out/share/bash-completion/completions/nmcli
18− '';
19−
20− meta = {
21− homepage = "http://bash-completion.alioth.debian.org/";
14+ meta = with stdenv.lib; {
15+ homepage = https://github.com/scop/bash-completion;
2216 description = "Programmable completion for the bash shell";
23− license = "GPL";
24−
25− platforms = stdenv.lib.platforms.unix;
26− maintainers = [ stdenv.lib.maintainers.peti ];
17+ license = licenses.gpl2Plus;
18+ platforms = platforms.unix;
19+ maintainers = [ maintainers.peti ];
2720 };
2821}
pkgs/tools/audio/beets/default.nix+2−2
@@ -19,7 +19,7 @@
1919, enableAlternatives ? false
2020, enableCopyArtifacts ? false
2121
22−, bashInteractive, bashCompletion
22+, bashInteractive, bash-completion
2323}:
2424
2525assert enableAcoustid -> pythonPackages.pyacoustid != null;
@@ -70,7 +70,7 @@ let
7070 allEnabledPlugins = pluginsWithoutDeps ++ enabledOptionalPlugins;
7171
7272 testShell = "${bashInteractive}/bin/bash --norc";
73− completion = "${bashCompletion}/share/bash-completion/bash_completion";
73+ completion = "${bash-completion}/share/bash-completion/bash_completion";
7474
7575in pythonPackages.buildPythonApplication rec {
7676 name = "beets-${version}";
pkgs/tools/misc/colord/default.nix+2−2
@@ -1,4 +1,4 @@
1−{ stdenv, fetchzip, fetchgit, bashCompletion
1+{ stdenv, fetchzip, fetchgit, bash-completion
22, glib, polkit, pkgconfig, intltool, gusb, libusb1, lcms2, sqlite, systemd, dbus
33, automake, autoconf, libtool, gtk_doc, which, gobjectIntrospection, argyllcms
44, libgudev, sane-backends }:
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
2828 '';
2929
3030 buildInputs = [ glib polkit pkgconfig intltool gusb libusb1 lcms2 sqlite systemd dbus gobjectIntrospection
31− bashCompletion argyllcms automake autoconf libgudev sane-backends ];
31+ bash-completion argyllcms automake autoconf libgudev sane-backends ];
3232
3333 postInstall = ''
3434 mkdir -p $out/etc/bash_completion.d
pkgs/tools/package-management/createrepo_c/default.nix+2−2
@@ -1,4 +1,4 @@
1−{ stdenv, fetchFromGitHub, cmake, pkgconfig, bzip2, expat, glib, curl, libxml2, python, rpm, openssl, sqlite, file, xz, pcre, bashCompletion }:
1+{ stdenv, fetchFromGitHub, cmake, pkgconfig, bzip2, expat, glib, curl, libxml2, python, rpm, openssl, sqlite, file, xz, pcre, bash-completion }:
22
33stdenv.mkDerivation rec {
44 rev = "0.10.0";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
2222 "set (PYTHON_INSTALL_DIR "$out/${python.sitePackages}")"
2323 '';
2424
25− buildInputs = [ cmake pkgconfig bzip2 expat glib curl libxml2 python rpm openssl sqlite file xz pcre bashCompletion ];
25+ buildInputs = [ cmake pkgconfig bzip2 expat glib curl libxml2 python rpm openssl sqlite file xz pcre bash-completion ];
2626
2727 meta = with stdenv.lib; {
2828 description = "C implementation of createrepo";
pkgs/tools/package-management/packagekit/default.nix+2−2
@@ -3,7 +3,7 @@
33, gobjectIntrospection, vala_0_23, gtk_doc, autoreconfHook, autoconf-archive
44, nix, boost
55, enableCommandNotFound ? false
6−, enableBashCompletion ? false, bashCompletion ? null }:
6+, enableBashCompletion ? false, bash-completion ? null }:
77
88stdenv.mkDerivation rec {
99 name = "packagekit-${version}";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
1717 };
1818
1919 buildInputs = [ glib polkit systemd python gobjectIntrospection vala_0_23 ]
20− ++ lib.optional enableBashCompletion bashCompletion;
20+ ++ lib.optional enableBashCompletion bash-completion;
2121 propagatedBuildInputs = [ sqlite nix boost ];
2222 nativeBuildInputs = [ intltool pkgconfig autoreconfHook autoconf-archive gtk_doc ];
2323
pkgs/top-level/aliases.nix+1
@@ -24,6 +24,7 @@ doNotDisplayTwice rec {
2424 asciidocFull = asciidoc-full; # added 2014-06-22
2525 bar = lemonbar; # added 2015-01-16
2626 bar-xft = lemonbar-xft; # added 2015-01-16
27+ bashCompletion = bash-completion; # Added 2016-09-28
2728 bridge_utils = bridge-utils; # added 2015-02-20
2829 btrfsProgs = btrfs-progs; # added 2016-01-03
2930 bundler_HEAD = bundler; # added 2015-11-15
pkgs/top-level/all-packages.nix+1−1
@@ -4337,7 +4337,7 @@ in
43374337 interactive = true;
43384338 });
43394339
4340− bashCompletion = callPackage ../shells/bash-completion { };
4340+ bash-completion = callPackage ../shells/bash-completion { };
43414341
43424342 dash = callPackage ../shells/dash { };
43434343