nixpkgs/pkgs/applications/networking/browsers/browsh/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

47 lines
1.2 KiB
Nix
Raw Normal View History

2022-07-23 20:55:49 +00:00
{ lib, buildGoModule, fetchurl, fetchFromGitHub }:
2018-07-30 19:32:22 +00:00
let
2022-07-23 20:55:49 +00:00
version = "1.8.0";
2018-07-30 19:32:22 +00:00
# TODO: must build the extension instead of downloading it. But since it's
# literally an asset that is indifferent regardless of the platform, this
# might be just enough.
webext = fetchurl {
2022-07-23 20:55:49 +00:00
url = "https://github.com/browsh-org/browsh/releases/download/v${version}/browsh-${version}.xpi";
sha256 = "sha256-12xWbf4ngYHWLKV9yyxyi0Ny/zHSj2o7Icats+Ef+pA=";
2018-07-30 19:32:22 +00:00
};
2022-07-23 20:55:49 +00:00
in
buildGoModule rec {
2018-07-30 19:32:22 +00:00
inherit version;
pname = "browsh";
2018-07-30 19:32:22 +00:00
2022-07-23 20:55:49 +00:00
sourceRoot = "source/interfacer";
2018-07-30 19:32:22 +00:00
src = fetchFromGitHub {
owner = "browsh-org";
repo = "browsh";
rev = "v${version}";
2022-07-23 20:55:49 +00:00
sha256 = "sha256-/tH1w6qi+rimsqtk8Y8AYljU3X4vbmoDtV07piWSBdw=";
2018-07-30 19:32:22 +00:00
};
2022-07-23 20:55:49 +00:00
vendorSha256 = "sha256-eCvV3UuM/JtCgMqvwvqWF3bpOmPSos5Pfhu6ETaS58c=";
2018-07-30 19:32:22 +00:00
preBuild = ''
2022-07-23 20:55:49 +00:00
cp "${webext}" src/browsh/browsh.xpi
2018-07-30 19:32:22 +00:00
'';
2022-07-23 20:55:49 +00:00
# Tests require network access
doCheck = false;
2018-07-30 19:32:22 +00:00
meta = with lib; {
2018-07-30 19:32:22 +00:00
description = "A fully-modern text-based browser, rendering to TTY and browsers";
homepage = "https://www.brow.sh/";
2022-07-23 20:55:49 +00:00
maintainers = with maintainers; [ kalbasit siraben ];
2021-01-15 13:21:58 +00:00
license = lib.licenses.lgpl21;
platforms = lib.platforms.linux ++ lib.platforms.darwin;
2018-07-30 19:32:22 +00:00
};
}