Unverified Commit c7d9444e authored by nat's avatar nat
Browse files

steamguard-cli: setup shell completions

parent e12d996e
Loading
Loading
Loading
Loading
+10 −1
Original line number Diff line number Diff line
{ lib
{ installShellFiles
, lib
, rustPlatform
, fetchFromGitHub
}:
@@ -16,6 +17,14 @@ rustPlatform.buildRustPackage rec {

  cargoHash = "sha256-qQA7UdtFqGPyCRHdV+FfbQFiPaOeW4rT4dYC3BeHDw0=";

  nativeBuildInputs = [ installShellFiles ];
  postInstall = ''
    installShellCompletion --cmd steamguard \
      --bash <($out/bin/steamguard completion --shell bash) \
      --fish <($out/bin/steamguard completion --shell fish) \
      --zsh <($out/bin/steamguard completion --shell zsh) \
  '';

  meta = with lib; {
    changelog = "https://github.com/dyc3/steamguard-cli/releases/tag/v${version}";
    description = "A linux utility for generating 2FA codes for Steam and managing Steam trade confirmations.";