#!/bin/sh
my_path="$(dirname "$(readlink -f "$0")")"
app_dir="$(dirname "$my_path")"

src="$app_dir/src"
res="$app_dir/builded_bins"

mkdir -p "$res"

build () {
    go build -o "$1" -v -x
}

cd "$src"
go fmt
build "$res/host"
GOOS=windows GOARCH=amd64 build "$res/host.exe"
