From f0fbd9deec95a6f71a31f4516374c006a16d18ad Mon Sep 17 00:00:00 2001 From: zowoq <59103226+zowoq@users.noreply.github.com> Date: Sat, 16 May 2020 13:37:01 +1000 Subject: [PATCH] umoci: install manpages, switch to buildGoModule --- .../virtualization/umoci/default.nix | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/virtualization/umoci/default.nix b/pkgs/applications/virtualization/umoci/default.nix index f07bb0fc164e..d8a1f36dd5d3 100644 --- a/pkgs/applications/virtualization/umoci/default.nix +++ b/pkgs/applications/virtualization/umoci/default.nix @@ -1,6 +1,11 @@ -{ lib, fetchFromGitHub, buildGoPackage }: +{ lib +, fetchFromGitHub +, buildGoModule +, go-md2man +, installShellFiles +}: -buildGoPackage rec { +buildGoModule rec { pname = "umoci"; version = "0.4.5"; @@ -11,10 +16,18 @@ buildGoPackage rec { sha256 = "1gzj4nnys73wajdwjn5jsskvnhzh8s2vmyl76ax8drpvw19bd5g3"; }; - goPackagePath = "github.com/openSUSE/umoci"; + vendorSha256 = null; buildFlagsArray = [ "-ldflags=-s -w -X main.version=${version}" ]; + nativeBuildInputs = [ go-md2man installShellFiles ]; + + postInstall = '' + sed -i '/SHELL =/d' Makefile + make local-doc + installManPage doc/man/*.[1-9] + ''; + meta = with lib; { description = "umoci modifies Open Container images"; homepage = "https://umo.ci";