lol
1{
2 lib,
3 installShellFiles,
4 runCommandLocal,
5}:
6
7runCommandLocal "install-shell-files--install-completion-output"
8 {
9 outputs = [
10 "out"
11 "bin"
12 ];
13 nativeBuildInputs = [ installShellFiles ];
14 meta.platforms = lib.platforms.all;
15 }
16 ''
17 echo foo > foo
18
19 installShellCompletion --bash foo
20
21 # assert it didn't go into $out
22 [[ ! -f $out/share/bash-completion/completions/foo ]]
23
24 cmp foo ''${!outputBin:?}/share/bash-completion/completions/foo
25
26 touch $out
27 ''