mirror of
https://codeberg.org/superseriousbusiness/gotosocial.git
synced 2024-12-18 07:01:49 +03:00
4f3b3f5c0b
Addresses #71 : Set version on the CLI framework. Add a build.sh script that injects variables into the build tooling using git and a version file. Set version in config.
8 lines
180 B
Bash
Executable file
8 lines
180 B
Bash
Executable file
#!/bin/sh
|
|
|
|
set -eu
|
|
|
|
export COMMIT=$(git rev-list -1 HEAD)
|
|
export VERSION=$(cat ./version)
|
|
|
|
go build -ldflags="-X 'main.Commit=$COMMIT' -X 'main.Version=$VERSION'" ./cmd/gotosocial
|