diff options
author | Jake Buchholz <tomalok@gmail.com> | 2019-01-10 02:01:58 +0000 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2019-01-10 09:33:59 +0000 |
commit | 3bd24cb5a6f2b8e1bbc27a11c83c861c7e8c9ca5 (patch) | |
tree | 83a4e24ec2db250727303cce5bb4136c2502e036 /community | |
parent | 201e763325c6b3e7d6e669e049df34e86f54bbb3 (diff) | |
download | aports-3bd24cb5a6f2b8e1bbc27a11c83c861c7e8c9ca5.tar.bz2 aports-3bd24cb5a6f2b8e1bbc27a11c83c861c7e8c9ca5.tar.xz |
community/go-md2man: new aport
Adding an explicit go-md2man package, as a number of other packages (runc, containerd, docker, etc.) are building it for the sole purpose of converting markdown documentation to man pages... (often with 'go get', which has raised some unanswered questions.)
Diffstat (limited to 'community')
-rw-r--r-- | community/go-md2man/APKBUILD | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/community/go-md2man/APKBUILD b/community/go-md2man/APKBUILD new file mode 100644 index 0000000000..e60ca8a38b --- /dev/null +++ b/community/go-md2man/APKBUILD @@ -0,0 +1,36 @@ +# Contributor: Jake Buchholz <tomalok@gmail.com> +# Maintainer: Jake Buchholz <tomalok@gmail.com> + +pkgname=go-md2man +pkgver=1.0.8 +pkgrel=0 +pkgdesc="Utility to convert markdown to man pages" +url="https://github.com/cpuguy83/go-md2man" +arch="all" +license="MIT" +makedepends="go" +subpackages="$pkgname-doc" +source="go-md2man-$pkgver.tar.gz::https://github.com/cpuguy83/go-md2man/archive/v$pkgver.tar.gz" +builddir="$srcdir/src/github.com/cpuguy83/go-md2man" + +build() { + cd "$srcdir" + export GOPATH="$PWD" + mkdir -p $(dirname "$builddir") + ln -s "$PWD/go-md2man-$pkgver" "$builddir" + cd $builddir + CGO_ENABLED=0 go build +} + +check() { + cd "$builddir" + ./go-md2man -in go-md2man.1.md -out go-md2man.1 +} + +package() { + cd "$builddir" + install -Dsm755 go-md2man "$pkgdir"/usr/bin/go-md2man + install -Dm644 go-md2man.1 "$pkgdir"/usr/share/man/man1/go-md2man.1 +} + +sha512sums="4c52e01c9b07582b5d55d1e94935378a676bd284a3e8230a8a191d4678b1b6ae92b704a249117c542832170069a70c649e58a1752fb2973709259b5bc108db91 go-md2man-1.0.8.tar.gz" |