1
0
mirror of https://github.com/ddworken/hishtory.git synced 2025-03-30 18:48:29 +02:00

another attempt at ldflags

This commit is contained in:
David Dworken 2022-04-08 22:45:49 -07:00
parent c42bb66e96
commit f2c6f86204
3 changed files with 6 additions and 4 deletions

View File

@ -20,9 +20,7 @@ jobs:
fetch-depth: 0 fetch-depth: 0
- id: ldflags - id: ldflags
run: | run: |
GIT_HASH=$(git rev-list -1 HEAD) echo "::set-output name=ldflags::$(./scripts/client-ldflags)"
LD_FLAGS="-X main.GitCommit=$GIT_HASH -w -extldflags \"-static\""
echo "::set-output name=value::$LD_FLAGS"
# Trusted builder. # Trusted builder.
build: build:

View File

@ -1 +1 @@
4 5

4
scripts/client-ldflags Executable file
View File

@ -0,0 +1,4 @@
#!/usr/bin/env bash
GIT_HASH=$(git rev-parse HEAD)
echo "-X main.GitCommit=$GIT_HASH -w -extldflags \"-static\""