mirror of
https://github.com/fosrl/pangolin.git
synced 2026-05-06 08:56:45 -05:00
[PR #2499] [MERGED] enhance(installer): use ldflags to inject versions #2998
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/fosrl/pangolin/pull/2499
Author: @LaurenceJJones
Created: 2/18/2026
Status: ✅ Merged
Merged: 2/25/2026
Merged by: @oschwartz10612
Base:
dev← Head:feature/build-variables📝 Commits (1)
9460e28ehance(installer): use ldflags to inject versions📊 Changes
3 files changed (+34 additions, -53 deletions)
View changed files
📝
.github/workflows/cicd.yml(+5 -13)📝
install/Makefile(+17 -34)📝
install/main.go(+12 -6)📄 Description
Community Contribution License Agreement
By creating this pull request, I grant the project maintainers an unlimited,
perpetual license to use, modify, and redistribute these contributions under any terms they
choose, including both the AGPLv3 and the Fossorial Commercial license terms. I
represent that I have the right to grant this license for all contributed content.
Description
Instead of the CI/CD using sed to replace the 'replaceme' text we can instead use ldflags which can inject variables at build time to the versions. The makefile had a bunch of workarounds for dev so these have been removed to cleanup etc etc and fetchs versions from the gh api directly if the variables are not injected like the CI/CD does
How to test?
Using
makeor explicitmake go-build-release PANGOLIN_VERSION=1.15.4 GERBIL_VERSION=1.0.0 BADGER_VERSION=1.0.0will inject the variables into the binary without usingsed🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.