Go SDK for Reforge Feature Flags and Config as a Service: https://www.reforge.com
go get github.com/ReforgeHQ/sdk-go@latest
package main
import (
"fmt"
"log"
"os"
reforge "github.com/ReforgeHQ/sdk-go"
)
func main() {
sdkKey, exists := os.LookupEnv("REFORGE_SDK_KEY")
if !exists {
log.Fatal("SDK Key not found")
}
client, err := reforge.NewSdk(reforge.WithSdkKey(sdkKey))
if err != nil {
log.Fatal(err)
}
val, ok, err := client.GetStringValue("my.string.config", *reforge.NewContextSet())
if err != nil {
log.Fatal(err)
}
if !ok {
log.Fatal("Value not found")
}
fmt.Println(val)
}
-
On feature branch: Run
./scripts/prepare-release.sh v1.0.0
- Updates
internal/version.go
with new version - Commits the version bump
- Updates
-
Create PR and merge to main
-
Automatic: GitHub Actions will detect version change and:
- Create git tag (e.g.,
v1.0.0
) - Create GitHub release
- Make version available:
go get github.com/ReforgeHQ/sdk-go@v1.0.0
- Create git tag (e.g.,
- Bump version in internal/version.go (this is the version header clients send)
- Commit that change on a branch and merge into main
- git tag with the new version number and push that to origin