Skip to content

Commit 57460ca

Browse files
magic-wormhole: install shell completions
1 parent 66576dc commit 57460ca

File tree

1 file changed

+9
-0
lines changed
  • pkgs/development/python-modules/magic-wormhole

1 file changed

+9
-0
lines changed

pkgs/development/python-modules/magic-wormhole/default.nix

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
stdenv,
44
buildPythonPackage,
55
fetchFromGitHub,
6+
installShellFiles,
67

78
# build-system
89
setuptools,
@@ -88,6 +89,10 @@ buildPythonPackage rec {
8889
dilation = [ noiseprotocol ];
8990
};
9091

92+
nativeBuildInputs = [
93+
installShellFiles
94+
];
95+
9196
nativeCheckInputs =
9297
[
9398
magic-wormhole-mailbox-server
@@ -101,6 +106,10 @@ buildPythonPackage rec {
101106

102107
postInstall = ''
103108
install -Dm644 docs/wormhole.1 $out/share/man/man1/wormhole.1
109+
installShellCompletion --cmd ${meta.mainProgram} \
110+
--bash wormhole_complete.bash \
111+
--fish wormhole_complete.fish \
112+
--zsh wormhole_complete.zsh
104113
'';
105114

106115
meta = {

0 commit comments

Comments
 (0)