ocamlPackages.hxd: 0.3.2 -> 0.3.3 (#364231)
[NixPkgs.git] / pkgs / by-name / mi / mihomo / package.nix
blob3544d85498196182c41bf4c98b123d16c937545f
2   lib,
3   fetchFromGitHub,
4   buildGoModule,
5   nixosTests,
6 }:
8 buildGoModule rec {
9   pname = "mihomo";
10   version = "1.19.0";
12   src = fetchFromGitHub {
13     owner = "MetaCubeX";
14     repo = "mihomo";
15     rev = "v${version}";
16     hash = "sha256-SUXxNHsbqbRtky456irkFotjMlbXPuBhNrHHZABGbPM=";
17   };
19   vendorHash = "sha256-whH9nEUddXd+xkgoCatkmfddTxK3BFZdi/TyTiabnDc=";
21   excludedPackages = [ "./test" ];
23   ldflags = [
24     "-s"
25     "-w"
26     "-X github.com/metacubex/mihomo/constant.Version=${version}"
27   ];
29   tags = [
30     "with_gvisor"
31   ];
33   # network required
34   doCheck = false;
36   passthru.tests = {
37     mihomo = nixosTests.mihomo;
38   };
40   meta = with lib; {
41     description = "Rule-based tunnel in Go";
42     homepage = "https://github.com/MetaCubeX/mihomo/tree/Alpha";
43     license = licenses.gpl3Only;
44     maintainers = with maintainers; [ oluceps ];
45     mainProgram = "mihomo";
46   };