summary refs log tree commit diff
path: root/nixos/modules
diff options
context:
space:
mode:
authorTor Hedin Brønner <torhedinbronner@gmail.com>2017-12-10 09:54:00 +0100
committerTor Hedin Brønner <torhedinbronner@gmail.com>2017-12-10 10:15:41 +0100
commit9988224c2a1632ae9ee9ab0ba19b79e014d4f681 (patch)
tree08e1b4dbc0a086e30dc37e43ef8f2440272975cc /nixos/modules
parentc6fbf4a15af676068776ff05cc4fc1bfed477b51 (diff)
downloadnixlib-9988224c2a1632ae9ee9ab0ba19b79e014d4f681.tar
nixlib-9988224c2a1632ae9ee9ab0ba19b79e014d4f681.tar.gz
nixlib-9988224c2a1632ae9ee9ab0ba19b79e014d4f681.tar.bz2
nixlib-9988224c2a1632ae9ee9ab0ba19b79e014d4f681.tar.lz
nixlib-9988224c2a1632ae9ee9ab0ba19b79e014d4f681.tar.xz
nixlib-9988224c2a1632ae9ee9ab0ba19b79e014d4f681.tar.zst
nixlib-9988224c2a1632ae9ee9ab0ba19b79e014d4f681.zip
nixos/programs/bash: Let bash-completion lazy load scripts
As described in detail here: https://github.com/NixOS/nixpkgs/issues/32533
bash will load completion scripts in $p/share/bash-completion/completions/ on
startup instead of letting bash-completion do it's lazy loading. Bash startup
will then slow down (very noticeable when bash-completion is installed in a
profile).

This commit leaves loading of scripts in the hands of bash-completion,
improving startup time for everyone using `enableCompletion`.

fixes #32533
Diffstat (limited to 'nixos/modules')
-rw-r--r--nixos/modules/programs/bash/bash.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/nixos/modules/programs/bash/bash.nix b/nixos/modules/programs/bash/bash.nix
index ef1acdfe66e6..52d3780e045c 100644
--- a/nixos/modules/programs/bash/bash.nix
+++ b/nixos/modules/programs/bash/bash.nix
@@ -20,7 +20,7 @@ let
       nullglobStatus=$(shopt -p nullglob)
       shopt -s nullglob
       for p in $NIX_PROFILES; do
-        for m in "$p/etc/bash_completion.d/"* "$p/share/bash-completion/completions/"*; do
+        for m in "$p/etc/bash_completion.d/"*; do
           . $m
         done
       done