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
2023-06-30 02:25:44 +00:00
version = "1.8.2";
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";
2023-06-30 02:25:44 +00:00
hash = "sha256-04rLyQt8co3Z7UJnDJmj++E4n7of0Zh1jQ90Bfwnx5A=";
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}";
2023-06-30 02:25:44 +00:00
hash = "sha256-KbBVcNuERBL94LuRx872zpjQTzR6c5GalsBoNR52SuQ=";
2018-07-30 19:32:22 +00:00
};
2023-06-30 02:25:44 +00:00
vendorHash = "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
};
}