nixpkgs/pkgs/applications/misc/break-time/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

54 lines
1003 B
Nix
Raw Normal View History

2020-07-19 13:31:40 +00:00
{ fetchFromGitHub
, glib
, gtk3
, openssl
, pkg-config
, python3
, rustPlatform
, lib
2020-07-19 13:31:40 +00:00
, wrapGAppsHook
}:
rustPlatform.buildRustPackage rec {
pname = "break-time";
2022-07-13 11:30:38 +00:00
version = "0.1.2";
2020-07-19 13:31:40 +00:00
src = fetchFromGitHub {
owner = "cdepillabout";
repo = "break-time";
rev = "v${version}";
2022-07-13 11:30:38 +00:00
sha256 = "sha256-q79JXaBwd/oKtJPvK2+72pY2YvaR3of2CMC8cF6wwQ8=";
2020-07-19 13:31:40 +00:00
};
cargoLock = {
lockFile = ./Cargo.lock;
};
2020-07-19 13:31:40 +00:00
nativeBuildInputs = [
pkg-config
python3 # needed for Rust xcb package
wrapGAppsHook
];
buildInputs = [
glib
gtk3
openssl
];
# update Cargo.lock to work with openssl
postPatch = ''
ln -sf ${./Cargo.lock} Cargo.lock
'';
meta = with lib; {
2020-07-19 13:31:40 +00:00
description = "Break timer that forces you to take a break";
mainProgram = "break-time";
2020-07-19 13:31:40 +00:00
homepage = "https://github.com/cdepillabout/break-time";
license = with licenses; [ mit ];
maintainers = with maintainers; [ cdepillabout ];
platforms = platforms.linux;
};
}