We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
{{branch}}
When using {{branch}} variable in a pull_request event the output is '' (as documented).
pull_request
It would be super useful to have it populated with github.event.pull_request.head.ref to compose tags like the following:
github.event.pull_request.head.ref
id: meta uses: docker/metadata-action@v5 with: images: ${{ github.repository }} tags: | type=sha,format=short,prefix={{branch}}-
At the moment I'm doing something like:
id: meta uses: docker/metadata-action@v5 with: images: ${{ github.repository }} tags: | type=sha,format=short,prefix=${{ github.event_name == 'pull_request' && github.event.pull_request.head.ref || '{{branch}}' }}-
But it seems a hack to me, is there any drawback in doing that?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Description
When using
{{branch}}
variable in apull_request
event the output is '' (as documented).It would be super useful to have it populated with
github.event.pull_request.head.ref
to compose tags like the following:At the moment I'm doing something like:
But it seems a hack to me, is there any drawback in doing that?
The text was updated successfully, but these errors were encountered: