mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-15 09:23:37 +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.
48 lines
1.1 KiB
Nix
48 lines
1.1 KiB
Nix
{ lib
|
|
, buildGoModule
|
|
, fetchFromGitHub
|
|
, librsvg
|
|
, pkg-config
|
|
, gtk3
|
|
, gtk-layer-shell
|
|
, wrapGAppsHook3 }:
|
|
|
|
buildGoModule rec {
|
|
pname = "nwg-bar";
|
|
version = "0.1.6";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "nwg-piotr";
|
|
repo = pname;
|
|
rev = "v${version}";
|
|
sha256 = "sha256-5N+WKZ+fuHQ0lVLd95/KkNAwzg/C4ImZ4DnSuKNGunk=";
|
|
};
|
|
|
|
patches = [ ./fix-paths.patch ];
|
|
postPatch = ''
|
|
substituteInPlace config/bar.json --subst-var out
|
|
substituteInPlace tools.go --subst-var out
|
|
'';
|
|
|
|
vendorHash = "sha256-/kqhZcIuoN/XA0i1ua3lzVGn4ghkekFYScL1o3kgBX4=";
|
|
|
|
nativeBuildInputs = [ pkg-config wrapGAppsHook3 ];
|
|
|
|
buildInputs = [ gtk3 gtk-layer-shell librsvg ];
|
|
|
|
preInstall = ''
|
|
mkdir -p $out/share/nwg-bar
|
|
cp -r config/* images $out/share/nwg-bar
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description =
|
|
"GTK3-based button bar for sway and other wlroots-based compositors";
|
|
mainProgram = "nwg-bar";
|
|
homepage = "https://github.com/nwg-piotr/nwg-bar";
|
|
license = licenses.mit;
|
|
platforms = platforms.linux;
|
|
maintainers = with maintainers; [ sei40kr ];
|
|
};
|
|
}
|