buildkite / buildkite/interpolate

Add ability to use find and replace interpolation

Open
#8 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
Go
Stars
36
Forks
6
PR merge metrics
No merged PRs in 30d

Description

It would be very helpful to be able to do simple find and replace with interpolation. My use case, for example, would be to use the Git branch name as a Docker image tag but to do so I need to replace certain characters that are valid in Git but not in Docker — e.g., replace forward slashes with dashes.

It would be great to be able to do something like this:

```
- label: "Push images tagged with Git branch"
plugins:
- docker-compose#v3.7.0:
config: buildkite/docker/compose.yml
push:
- foo:123456789.dkr.ecr.eu-west-2.amazonaws.com/foo:${BUILDKITE_BRANCH//\\//--}
```

There you can see the desired interpolation that converts a `/` character to `--`

I'm afraid I don't know Go so can't offer a PR.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.