{
  description = "pass-autotype";

  inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";

  outputs = { self, nixpkgs }:
    let
      system = "x86_64-linux";
      pkgs = import nixpkgs { inherit system; };

      runtimePath = pkgs.lib.makeBinPath [
        pkgs.fuzzel
        pkgs.wtype
        pkgs.pass
        pkgs.libnotify
      ];
    in {
      packages.${system}.default = pkgs.stdenv.mkDerivation {
        pname = "pass-autotype";
        version = "0.5";

        src = self;

        dontBuild = true;

        installPhase = ''
          mkdir -p $out/bin
          install -Dm755 pass-autotype $out/bin/pass-autotype

          wrapProgram $out/bin/pass-autotype \
            --prefix PATH : ${runtimePath}
        '';

        nativeBuildInputs = [ pkgs.makeWrapper ];

        meta = with pkgs.lib; {
          description = "Autotype passwords from pass using fuzzel and wtype";
          license = licenses.mit;
          platforms = platforms.linux;
        };
      };
    };
}
