depot/third_party/nixpkgs/pkgs/misc/screensavers/betterlockscreen/default.nix
Default email e0d1b75f19 Project import generated by Copybara.
GitOrigin-RevId: fe01052444c1d66ed6ef76df2af798c9769e9e79
2021-08-10 22:31:46 +08:00

55 lines
1.2 KiB
Nix

{ fetchFromGitHub
, lib
, makeWrapper
, stdenv
# Dependencies (@see https://github.com/pavanjadhaw/betterlockscreen/blob/master/shell.nix)
, bc
, coreutils
, i3lock-color
, gawk
, gnugrep
, gnused
, imagemagick
, procps
, xdpyinfo
, xrandr
, xset
}:
stdenv.mkDerivation rec {
pname = "betterlockscreen";
version = "4.0.0";
src = fetchFromGitHub {
owner = "pavanjadhaw";
repo = "betterlockscreen";
rev = "v${version}";
sha256 = "1ha1yddrcmbsdljdg3gn7i42csbw8h3zgf4i3mcsmbz8nsvc2wdc";
};
nativeBuildInputs = [ makeWrapper ];
installPhase =
let
PATH =
lib.makeBinPath
[ bc coreutils i3lock-color gawk gnugrep gnused imagemagick procps xdpyinfo xrandr xset ];
in ''
runHook preInstall
mkdir -p $out/bin
cp betterlockscreen $out/bin/betterlockscreen
wrapProgram "$out/bin/betterlockscreen" --prefix PATH : "$out/bin:${PATH}"
runHook preInstall
'';
meta = with lib; {
description = "Fast and sweet looking lockscreen for linux systems with effects!";
homepage = "https://github.com/pavanjadhaw/betterlockscreen";
license = licenses.mit;
platforms = platforms.linux;
maintainers = with maintainers; [ eyjhb sebtm ];
};
}