2017-02-13 14:01:54 -05:00
|
|
|
#!/usr/bin/env bash
|
2016-06-09 11:33:28 -04:00
|
|
|
#
|
|
|
|
# Generate man pages for docker/docker
|
|
|
|
#
|
|
|
|
|
|
|
|
set -eu
|
|
|
|
|
|
|
|
mkdir -p ./man/man1
|
|
|
|
|
2017-05-10 21:24:32 -04:00
|
|
|
MD2MAN_REPO=github.com/cpuguy83/go-md2man
|
|
|
|
MD2MAN_COMMIT=$(grep -F "$MD2MAN_REPO" vendor.conf | cut -d' ' -f2)
|
|
|
|
|
|
|
|
(
|
|
|
|
go get -d "$MD2MAN_REPO"
|
|
|
|
cd "$GOPATH"/src/"$MD2MAN_REPO"
|
|
|
|
git checkout "$MD2MAN_COMMIT" &> /dev/null
|
|
|
|
go install "$MD2MAN_REPO"
|
|
|
|
)
|
|
|
|
|
2016-06-09 11:33:28 -04:00
|
|
|
# Generate man pages from cobra commands
|
2017-06-06 00:59:50 -04:00
|
|
|
go build -o /tmp/gen-manpages github.com/docker/cli/man
|
2016-09-22 14:11:08 -04:00
|
|
|
/tmp/gen-manpages --root . --target ./man/man1
|
2016-06-09 11:33:28 -04:00
|
|
|
|
|
|
|
# Generate legacy pages from markdown
|
|
|
|
./man/md2man-all.sh -q
|