hack/go-mod-prepare.sh: find root robustly; make steps transparent
Signed-off-by: Bjorn Neergaard <bneergaard@mirantis.com>
(cherry picked from commit af8e955e8f
)
Signed-off-by: Bjorn Neergaard <bneergaard@mirantis.com>
This commit is contained in:
parent
036398f512
commit
c508d13372
1 changed files with 7 additions and 2 deletions
|
@ -1,8 +1,13 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
ROOTDIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
|
||||
set -e
|
||||
|
||||
cat > "${ROOTDIR}/go.mod" << EOF
|
||||
SCRIPTDIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
ROOTDIR="$(git -C "$SCRIPTDIR" rev-parse --show-toplevel)"
|
||||
|
||||
set -x
|
||||
|
||||
tee "${ROOTDIR}/go.mod" << EOF
|
||||
module github.com/docker/docker
|
||||
|
||||
go 1.18
|
||||
|
|
Loading…
Reference in a new issue