Add convenient build shortcut
This commit is contained in:
8
build.sh
Executable file
8
build.sh
Executable file
@@ -0,0 +1,8 @@
|
||||
#!/usr/bin/env bash
|
||||
set -e
|
||||
|
||||
GITCOMMIT=$(git rev-parse --short HEAD 2>/dev/null)
|
||||
DATE=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
|
||||
VERSION=$(git branch --show-current)
|
||||
|
||||
go build -ldflags "-X speedrun/cmd.version=$VERSION -X speedrun/cmd.commit=$GITCOMMIT -X speedrun/cmd.date=$DATE"
|
||||
Reference in New Issue
Block a user