bandwhich: 0.23.0 -> 0.23.1; move to by-name; nixfmt; useFetchCargoVendor (#356934)
[NixPkgs.git] / pkgs / by-name / tr / tridactyl-native / package.nix
blobc97b8cad3365039c5445faf72fbd8c5883f2f8d7
2   lib,
3   buildNimPackage,
4   fetchFromGitHub,
5 }:
6 buildNimPackage {
7   pname = "tridactyl-native";
8   version = "0.4.1";
10   src = fetchFromGitHub {
11     owner = "tridactyl";
12     repo = "native_messenger";
13     rev = "3059abd9fb3f14d598f6c299335c3ebac5bc689a";
14     hash = "sha256-gicdpWAoimZMNGLc8w0vtJiFFxeqxB8P4lgWDun7unM=";
15   };
17   lockFile = ./lock.json;
19   installPhase = ''
20     mkdir -p "$out/lib/mozilla/native-messaging-hosts"
21     sed -i -e "s|REPLACE_ME_WITH_SED|$out/bin/native_main|" "tridactyl.json"
22     cp tridactyl.json "$out/lib/mozilla/native-messaging-hosts/"
23   '';
25   meta = with lib; {
26     description = "Native messenger for Tridactyl, a vim-like Firefox webextension";
27     mainProgram = "native_main";
28     homepage = "https://github.com/tridactyl/native_messenger";
29     license = licenses.bsd2;
30     platforms = platforms.all;
31     maintainers = with maintainers; [
32       timokau
33       dit7ya
34       kiike
35     ];
36   };