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
28 lines
716 B
Nix
28 lines
716 B
Nix
{ lib, stdenv, fetchFromGitHub, pkg-config, gtk2 }:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "colorpicker";
|
|
version = "git-2018-01-14";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "Ancurio";
|
|
repo = "colorpicker";
|
|
rev = "287676947e6e3b5b0cee784aeb1638cf22f0ce17";
|
|
sha256 = "1kj1dpb79llrfpszraaz6r7ci114zqi5rmqxwsvq2dnnpjxyi29r";
|
|
};
|
|
|
|
nativeBuildInputs = [ pkg-config ];
|
|
buildInputs = [ gtk2 ];
|
|
|
|
installPhase = ''
|
|
install -Dt $out/bin colorpicker
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "Click on a pixel on your screen and print its color value in RGB";
|
|
homepage = "https://github.com/Ancurio/colorpicker";
|
|
maintainers = with maintainers; [ jb55 ];
|
|
license = licenses.mit;
|
|
};
|
|
}
|