mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-15 02:03:01 +00:00
571c71e6f7
We are migrating packages that meet below requirements: 1. using `callPackage` 2. called path is a directory 3. overriding set is empty (`{ }`) 4. not containing path expressions other than relative path (to makenixpkgs-vet happy) 5. not referenced by nix files outside of the directory, other than`pkgs/top-level/all-packages.nix` 6. not referencing nix files outside of the directory 7. not referencing `default.nix` (since it's changed to `package.nix`) 8. `outPath` doesn't change after migration The tool is here: https://github.com/Aleksanaa/by-name-migrate.
37 lines
976 B
Nix
37 lines
976 B
Nix
{ lib, stdenv, fetchFromGitHub, libX11, patches ? [ ], writeText, conf ? null }:
|
|
|
|
stdenv.mkDerivation {
|
|
pname = "dwmblocks";
|
|
version = "0-unstable-2024-08-24";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "torrinfail";
|
|
repo = "dwmblocks";
|
|
rev = "8cedd220684064f1433749ed2a19a6184c22cf07";
|
|
hash = "sha256-QtYQB2mvw1k2LA8D+/cVnA8+GRDWjhIM6rxfi/IGjEw=";
|
|
};
|
|
|
|
buildInputs = [ libX11 ];
|
|
|
|
inherit patches;
|
|
|
|
postPatch =
|
|
let
|
|
configFile =
|
|
if lib.isDerivation conf || builtins.isPath conf
|
|
then conf else writeText "blocks.def.h" conf;
|
|
in
|
|
lib.optionalString (conf != null) "cp ${configFile} blocks.def.h";
|
|
|
|
makeFlags = [ "PREFIX=$(out)" ];
|
|
|
|
meta = with lib; {
|
|
description = "Modular status bar for dwm written in c";
|
|
homepage = "https://github.com/torrinfail/dwmblocks";
|
|
license = licenses.isc;
|
|
maintainers = with maintainers; [ sophrosyne ];
|
|
platforms = platforms.linux;
|
|
mainProgram = "dwmblocks";
|
|
};
|
|
}
|