Skip to content

Commit

Permalink
Merge pull request #269433 from anthonyroussel/updates/photofield
Browse files Browse the repository at this point in the history
photofield: 0.11.0 -> 0.13.0
  • Loading branch information
risicle authored Nov 26, 2023
2 parents 3c9dd1c + 7e9c976 commit d3d8dc7
Showing 1 changed file with 14 additions and 6 deletions.
20 changes: 14 additions & 6 deletions pkgs/servers/photofield/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,19 @@
, makeWrapper
, exiftool
, ffmpeg
, testers
, photofield
}:

let
pname = "photofield-ui";
version = "0.11.0";
version = "0.13.0";

src = fetchFromGitHub {
owner = "SmilyOrg";
repo = "photofield";
rev = "v${version}";
hash = "sha256-AqOhagqH0wRKjwcRHFVw0izC0DBv9uY3B5MMDBJoFVE=";
rev = "refs/tags/v${version}";
hash = "sha256-6pJvOn3sN6zfjt2dVZ/xH6pSXM0WgbG7au9tSVUGYys=";
};

webui = buildNpmPackage {
Expand All @@ -24,7 +26,7 @@ let

sourceRoot = "${src.name}/ui";

npmDepsHash = "sha256-YVyaZsFh5bolDzMd5rXWrbbXQZBeEIV6Fh/kwN+rvPk=";
npmDepsHash = "sha256-trKcNuhRdiabFKMafOLtPg8x1bQHLOif6Hm4k5bTAYc=";

installPhase = ''
mkdir -p $out/share
Expand All @@ -37,7 +39,7 @@ buildGoModule rec {
pname = "photofield";
inherit version src;

vendorHash = "sha256-0rrBHkKZfStwzIv5Us/8Db6z3ZSqassCMWQMpScZq7Y=";
vendorHash = "sha256-4JFP3vs/Z8iSKgcwfxpdnQpO9kTF68XQArFHYP8IoDQ=";

preBuild = ''
cp -r ${webui}/share/photofield-ui ui/dist
Expand All @@ -50,7 +52,7 @@ buildGoModule rec {
"-X main.builtBy=Nix"
];

tags = [ "embedstatic" ];
tags = [ "embedui" ];

doCheck = false; # tries to modify filesytem

Expand All @@ -61,10 +63,16 @@ buildGoModule rec {
--prefix PATH : "${lib.makeBinPath [exiftool ffmpeg]}"
'';

passthru.tests.version = testers.testVersion {
package = photofield;
command = "photofield -version";
};

meta = with lib; {
description = "Experimental fast photo viewer";
homepage = "https://github.com/SmilyOrg/photofield";
license = licenses.mit;
mainProgram = "photofield";
maintainers = with maintainers; [ dit7ya ];
};
}

0 comments on commit d3d8dc7

Please sign in to comment.