mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-23 07:23:20 +00:00
bitcoin: add shell completions
This commit is contained in:
parent
19c6ce8a9b
commit
5dacf3a0d8
@ -3,6 +3,7 @@
|
||||
, fetchurl
|
||||
, autoreconfHook
|
||||
, pkg-config
|
||||
, installShellFiles
|
||||
, util-linux
|
||||
, hexdump
|
||||
, autoSignDarwinBinariesHook
|
||||
@ -43,7 +44,7 @@ stdenv.mkDerivation rec {
|
||||
};
|
||||
|
||||
nativeBuildInputs =
|
||||
[ autoreconfHook pkg-config ]
|
||||
[ autoreconfHook pkg-config installShellFiles ]
|
||||
++ lib.optionals stdenv.isLinux [ util-linux ]
|
||||
++ lib.optionals stdenv.isDarwin [ hexdump ]
|
||||
++ lib.optionals (stdenv.isDarwin && stdenv.isAarch64) [ autoSignDarwinBinariesHook ]
|
||||
@ -53,7 +54,19 @@ stdenv.mkDerivation rec {
|
||||
++ lib.optionals withWallet [ db48 sqlite ]
|
||||
++ lib.optionals withGui [ qrencode qtbase qttools ];
|
||||
|
||||
postInstall = lib.optionalString withGui ''
|
||||
postInstall = ''
|
||||
installShellCompletion --cmd bitcoin-cli --bash contrib/completions/bash/bitcoin-cli.bash-completion
|
||||
installShellCompletion --cmd bitcoind --bash contrib/completions/bash/bitcoind.bash-completion
|
||||
installShellCompletion --cmd bitcoin-tx --bash contrib/completions/bash/bitcoin-tx.bash-completion
|
||||
|
||||
installShellCompletion --fish contrib/completions/fish/bitcoin-cli.fish
|
||||
installShellCompletion --fish contrib/completions/fish/bitcoind.fish
|
||||
installShellCompletion --fish contrib/completions/fish/bitcoin-tx.fish
|
||||
installShellCompletion --fish contrib/completions/fish/bitcoin-util.fish
|
||||
installShellCompletion --fish contrib/completions/fish/bitcoin-wallet.fish
|
||||
'' + lib.optionalString withGui ''
|
||||
installShellCompletion --fish contrib/completions/fish/bitcoin-qt.fish
|
||||
|
||||
install -Dm644 ${desktop} $out/share/applications/bitcoin-qt.desktop
|
||||
substituteInPlace $out/share/applications/bitcoin-qt.desktop --replace "Icon=bitcoin128" "Icon=bitcoin"
|
||||
install -Dm644 share/pixmaps/bitcoin256.png $out/share/pixmaps/bitcoin.png
|
||||
|
Loading…
Reference in New Issue
Block a user