blob: a6b3bd12191565f2ee00a5dc204b0b2904f7a565 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
#!/bin/bash
set -euo pipefail
cd /opt/app
if [ ! -e go.mod ]; then
printf "Error: This directory does not contain a go module;\n"
printf "vagrant-spk's golang stack does not support older GOPATH\n"
printf "based projects. Try running:\n" >&2
printf "\n" >&2
printf " vagrant-spk vm ssh\n" >&2
printf " cd /opt/app\n" >&2
printf " go mod init example.com/mypkg\n" >&2
exit 1
fi
go build -o tube
exit 0
|