stockholm/makefu/5pkgs/gen-oath-safe/default.nix

38 lines
782 B
Nix
Raw Normal View History

2021-12-04 20:24:48 +00:00
{ coreutils, makeWrapper, openssl, libcaca, qrencode, fetchFromGitHub, yubikey-manager, python, stdenv, lib, ... }:
2017-06-30 20:36:25 +00:00
stdenv.mkDerivation {
2017-09-04 15:48:12 +00:00
name = "gen-oath-safe-2017-06-30";
2017-06-30 20:36:25 +00:00
src = fetchFromGitHub {
owner = "mcepl";
repo = "gen-oath-safe";
rev = "fb53841";
sha256 = "0018kqmhg0861r5xkbis2a1rx49gyn0dxcyj05wap5ms7zz69m0m";
};
phases = [
"unpackPhase"
"installPhase"
"fixupPhase"
];
buildInputs = [ makeWrapper ];
installPhase =
let
2021-12-04 20:24:48 +00:00
path = lib.makeBinPath [
2017-06-30 20:36:25 +00:00
coreutils
openssl
qrencode
yubikey-manager
2017-06-30 20:36:25 +00:00
libcaca
python
];
in
''
mkdir -p $out/bin
cp gen-oath-safe $out/bin/
wrapProgram $out/bin/gen-oath-safe \
--prefix PATH : ${path}
'';
}