lol
at master 49 lines 1.2 kB view raw
1{ 2 lib, 3 buildGoModule, 4 fetchFromGitHub, 5 installShellFiles, 6 nixosTests, 7}: 8 9buildGoModule rec { 10 pname = "upterm"; 11 version = "0.15.3"; 12 13 src = fetchFromGitHub { 14 owner = "owenthereal"; 15 repo = "upterm"; 16 rev = "v${version}"; 17 hash = "sha256-9h4Poz0hUg5/7CrF0ZzT4KrVaFlhvcorIgZbleMpV6w="; 18 }; 19 20 vendorHash = "sha256-i92RshW5dsRE88X8bXyrj13va66cc0Yu/btpR0pvoSM="; 21 22 subPackages = [ 23 "cmd/upterm" 24 "cmd/uptermd" 25 ]; 26 27 nativeBuildInputs = [ installShellFiles ]; 28 29 postInstall = '' 30 # force go to build for build arch rather than host arch during cross-compiling 31 CGO_ENABLED=0 GOOS= GOARCH= go run cmd/gendoc/main.go 32 installManPage etc/man/man*/* 33 installShellCompletion --bash --name upterm.bash etc/completion/upterm.bash_completion.sh 34 installShellCompletion --zsh --name _upterm etc/completion/upterm.zsh_completion 35 ''; 36 37 doCheck = true; 38 39 passthru.tests = { inherit (nixosTests) uptermd; }; 40 41 __darwinAllowLocalNetworking = true; 42 43 meta = with lib; { 44 description = "Secure terminal-session sharing"; 45 homepage = "https://upterm.dev"; 46 license = licenses.asl20; 47 maintainers = with maintainers; [ hax404 ]; 48 }; 49}