Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/simenandre/setup-variables

⚡️ Map variables on Github Actions runs based on input
https://github.com/simenandre/setup-variables

action actions github-actions

Last synced: about 1 month ago
JSON representation

⚡️ Map variables on Github Actions runs based on input

Awesome Lists containing this project

README

        


setup variables variable mapper github actions

# Map variable with ease

```yaml
uses: simenandre/setup-variables@v2
id: stack
with:
key: ${{ env.CI_REF_NAME_SLUG }}
map: |
main: prod
staging: staging
dev: dev
'*': dev

```

## How does this compare to X?

There are multiple other Github Actions step that tries to solve similar/same
issues.

[variable-mapper](https://github.com/marketplace/actions/variable-mapper) for
instance, has mostly the same functionality as this. The schema design is mostly
the same, only difference being that the original uses JSON for mapping.