github.com/micro/go-micro/examples@v0.0.0-20210105173217-bf4ab679e18b/booking/bin/build.sh (about) 1 #!/bin/bash 2 3 dir=`pwd` 4 5 build() { 6 for d in $(ls ./$1); do 7 echo "building $1/$d" 8 pushd $dir/$1/$d >/dev/null 9 CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -ldflags '-w' 10 popd >/dev/null 11 done 12 } 13 14 build api 15 build srv