Skip to content

Commit

Permalink
chore: build script finish
Browse files Browse the repository at this point in the history
  • Loading branch information
Subilan committed Jul 31, 2024
1 parent a937e30 commit e162296
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
7 changes: 5 additions & 2 deletions build.sh
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
env GOOS=linux GOARCH=amd64
go build -o lab -ldflags='-X common.LastBuiltAt="date +%Y-%m-%d_%H:%M:%S"'
n=$(cat buildnumber)
nn=$((n+1))
env GOOS=linux GOARCH=amd64 TZ=Asia/Shanghai
go build -ldflags="-X seatimc/backend/common.LastBuiltAt=$nn.$(date +%Y-%m-%d_%H:%M:%S)+08:00" -o lab
echo $nn > buildnumber
1 change: 1 addition & 0 deletions buildnumber
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1

0 comments on commit e162296

Please sign in to comment.