iamtheyammer/Branch-based environment variables that rock

An easy way to set envronment variables based on the building branch. Check out the full README for instructions.

View on GitHub

Trust Signals

Scorecard Score
not yet scored
Maintenance Recency
Activelast commit Mar 19, 2026
License
MIT

Pinned Snippet

workflow.ymlSHA-pinned
uses: iamtheyammer/branch-env-vars@9bfe03f4cb49752366ccef1617254b920aeebf0d # v1.3.0

tags can be moved; commit SHAs can't. why a SHA?

namedescriptionrequireddefault
bevOverwriteOverwrite other, already-set environment variables with the same namenotrue
bevActionOnNoRefWhat to do when there is no GITHUB_REF: 'error' (fail the build), 'warn' (print a warning but pass), 'continue' (pass and continue silently) nowarn
bevSetEmptyVarsWhether to set an environment variable to an empty string if no value is providednotrue

no outputs