btrbk: add mainProgram
[NixPkgs.git] / pkgs / by-name / am / amfora / package.nix
blob9b658386725e0701acd92ed83e636739b00feab4
1 { stdenv, lib, fetchFromGitHub, buildGoModule }:
3 buildGoModule rec {
4   pname = "amfora";
5   version = "1.10.0";
7   src = fetchFromGitHub {
8     owner = "makeworld-the-better-one";
9     repo = "amfora";
10     rev = "v${version}";
11     hash = "sha256-KOuKgxH3n4rdF+oj/TwEcRqX1sn4A9e23FNwQMhMVO4=";
12   };
14   vendorHash = "sha256-T/hnlQMDOZV+QGl7xp29sBGfb4VXcXqN6PDoBFdpp4M=";
16   postInstall = lib.optionalString (!stdenv.hostPlatform.isDarwin) ''
17     sed -i "s:amfora:$out/bin/amfora:" amfora.desktop
18     install -Dm644 amfora.desktop -t $out/share/applications
19   '';
21   meta = with lib; {
22     description = "Fancy terminal browser for the Gemini protocol";
23     mainProgram = "amfora";
24     homepage = "https://github.com/makeworld-the-better-one/amfora";
25     license = with licenses; [ gpl3 ];
26     maintainers = with maintainers; [ deifactor ];
27     changelog = "https://github.com/makeworld-the-better-one/amfora/blob/v${version}/CHANGELOG.md";
28   };