1
0
mirror of https://github.com/docker/cli.git synced 2026-01-06 05:41:44 +03:00

Merge pull request #2877 from Foxboron/morten/fix-man

generate-man.sh: Only build md2man if it's not installed
This commit is contained in:
Silvin Lubecki
2020-12-10 09:41:38 +01:00
committed by GitHub

View File

@@ -4,8 +4,10 @@ set -eu -o pipefail
mkdir -p ./man/man1
# yay, go install creates a binary named "v2" ¯\_(ツ)_/¯
go build -o "/go/bin/md2man" ./vendor/github.com/cpuguy83/go-md2man/v2
if ! command -v md2man &> /dev/null; then
# yay, go install creates a binary named "v2" ¯\_(ツ)_/¯
go build -o "/go/bin/md2man" ./vendor/github.com/cpuguy83/go-md2man/v2
fi
# Generate man pages from cobra commands
go build -o /tmp/gen-manpages github.com/docker/cli/man