Merge pull request #36136 from hedning/nix-bash-completions-on-enableCompletion
programs/bash: install nix-bash-completions if completion is enabled
This commit is contained in:
commit
47ce3021a9
@ -430,6 +430,13 @@ following incompatible changes:</para>
|
|||||||
and <literal>stopJob</literal> provide an optional <literal>$user</literal> argument for that purpose.
|
and <literal>stopJob</literal> provide an optional <literal>$user</literal> argument for that purpose.
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
|
<listitem>
|
||||||
|
<para>
|
||||||
|
Enabling bash completion on NixOS, <literal>programs.bash.enableCompletion</literal>, will now also enable
|
||||||
|
completion for the Nix command line tools by installing the
|
||||||
|
<link xlink:href="https://github.com/hedning/nix-bash-completions">nix-bash-completions</link> package.
|
||||||
|
</para>
|
||||||
|
</listitem>
|
||||||
</itemizedlist>
|
</itemizedlist>
|
||||||
|
|
||||||
</section>
|
</section>
|
||||||
|
@ -211,6 +211,9 @@ in
|
|||||||
"/share/bash-completion"
|
"/share/bash-completion"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
environment.systemPackages = optional cfg.enableCompletion
|
||||||
|
pkgs.nix-bash-completions;
|
||||||
|
|
||||||
environment.shells =
|
environment.shells =
|
||||||
[ "/run/current-system/sw/bin/bash"
|
[ "/run/current-system/sw/bin/bash"
|
||||||
"/var/run/current-system/sw/bin/bash"
|
"/var/run/current-system/sw/bin/bash"
|
||||||
|
@ -1,14 +1,14 @@
|
|||||||
{ stdenv, fetchFromGitHub }:
|
{ stdenv, fetchFromGitHub }:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
version = "0.6.3";
|
version = "0.6.4";
|
||||||
name = "nix-bash-completions-${version}";
|
name = "nix-bash-completions-${version}";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "hedning";
|
owner = "hedning";
|
||||||
repo = "nix-bash-completions";
|
repo = "nix-bash-completions";
|
||||||
rev = "v${version}";
|
rev = "v${version}";
|
||||||
sha256 = "1zmk9f53xpwk5j6qqisjlddgm2fr68p1q6pn3wa14bd777lranhj";
|
sha256 = "1kdysrfc8dx24q438wj3aisn64g2w5yb6mx91qa385p5hz7b1yz2";
|
||||||
};
|
};
|
||||||
|
|
||||||
# To enable lazy loading via. bash-completion we need a symlink to the script
|
# To enable lazy loading via. bash-completion we need a symlink to the script
|
||||||
|
Loading…
x
Reference in New Issue
Block a user