mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-23 22:23:15 +00:00
4a7f99d55d
Part of: https://github.com/NixOS/nixpkgs/issues/108938 meta = with stdenv.lib; is a widely used pattern. We want to slowly remove the `stdenv.lib` indirection and encourage people to use `lib` directly. Thus let’s start with the meta field. This used a rewriting script to mostly automatically replace all occurances of this pattern, and add the `lib` argument to the package header if it doesn’t exist yet. The script in its current form is available at https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
52 lines
1.3 KiB
Nix
52 lines
1.3 KiB
Nix
{ lib, stdenv
|
|
, rustPlatform
|
|
, fetchFromGitHub
|
|
, pkg-config
|
|
, openssl
|
|
, gtk3
|
|
, rust
|
|
}:
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
pname = "effitask";
|
|
version = "1.4.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "sanpii";
|
|
repo = pname;
|
|
rev = version;
|
|
sha256 = "09bffxdp43s8b1rpmsgqr2kyz3i4jbd2yrwbxw21fj3sf3mwb9ig";
|
|
};
|
|
|
|
# workaround for missing Cargo.lock file https://github.com/sanpii/effitask/issues/48
|
|
cargoPatches = [ ./cargo-lock.patch ];
|
|
|
|
cargoSha256 = "0dvmp23kny6rlv6c0mfyy3cmz1bi5wcm1mxps4z67lym5kxfd362";
|
|
|
|
buildInputs = [ openssl gtk3 ];
|
|
|
|
nativeBuildInputs = [ pkg-config ];
|
|
|
|
# default installPhase don't install assets
|
|
installPhase = ''
|
|
runHook preInstall
|
|
make install PREFIX="$out" TARGET="target/${rust.toRustTarget stdenv.hostPlatform}/release/effitask"
|
|
runHook postInstall
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "Graphical task manager, based on the todo.txt format";
|
|
longDescription = ''
|
|
To use it as todo.sh add-on, create a symlink like this:
|
|
mkdir ~/.todo.actions.d/
|
|
ln -s $(which effitask) ~/.todo.actions.d/et
|
|
|
|
Or use it as standalone program by defining some environment variables
|
|
like described in the projects readme.
|
|
'';
|
|
homepage = "https://github.com/sanpii/effitask";
|
|
maintainers = with maintainers; [ davidak ];
|
|
license = with licenses; [ mit ];
|
|
};
|
|
}
|