actions-ecosystem / action-push-tag Goto Github PK
View Code? Open in Web Editor NEW๐ GitHub Action to push a Git tag
Home Page: https://github.com/marketplace/actions/actions-ecosystem-action-push-tag
License: Apache License 2.0
๐ GitHub Action to push a Git tag
Home Page: https://github.com/marketplace/actions/actions-ecosystem-action-push-tag
License: Apache License 2.0
Allow force for the tag, so that we can use this for walking tags. Eg - move the "dev" tag requires:
git tag -f && git push origin -f
Flexibility of this plugin for more use cases.
Ran the actions-ecosystem/action-push-tag@v1
Github Action unsuccessfully:
...
"/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/_temp/_runner_file_commands":"/github/file_commands" -v "/home/runner/work/.../...":"/github/workspace" ...
12
fatal: not in a git directory
Probably related to:
https://stackoverflow.com/questions/71849415/cannot-add-parent-directory-to-safe-directory-on-git
https://news.ycombinator.com/item?id=31009675
Successfully pushed tags.
I think if you run a workflow with the action-push-tag
action this will happen.
Currently, GITHUB_TOKEN
is used for authentication while pushing tags. This issue is for requesting a feature to support the use of deploy keys for pushing tags from the workflow.
From github documentation:
When you use the repository's GITHUB_TOKEN to perform tasks on behalf of the GitHub Actions app, events triggered by the GITHUB_TOKEN will not create a new workflow run. This prevents you from accidentally creating recursive workflow runs. For example, if a workflow run pushes code using the repository's GITHUB_TOKEN, a new workflow will not run even when the repository contains a workflow configured to run when push events occur.
This is a problem if the tag event is supposed to trigger any other workflows. - [Ref]
A proposed solution for this is to use the deploy keys for pushing the tag. - [Ref1], [Ref2]
Allow optional specification of the commit sha to tag.
In case we want to tag a previous commit or move a tag.
Hi!
I've been randomly getting the error remote: Repository not found
when running this action. Maybe 90% of the times my action is called, it works flawlessly, but the other 10% I get this error. It's a private repo if that makes any difference.
Run actions-ecosystem/action-push-tag@v1
/usr/bin/docker run --name a33c13ea4031e03954238a09053f19aed7a50_eb1757 --label 8a33c1 --workdir /github/workspace --rm -e INPUT_TAG -e INPUT_MESSAGE -e HOME -e GITHUB_JOB -e GITHUB_REF -e GITHUB_SHA -e GITHUB_REPOSITORY -e GITHUB_REPOSITORY_OWNER -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_RETENTION_DAYS -e GITHUB_ACTOR -e GITHUB_WORKFLOW -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GITHUB_EVENT_NAME -e GITHUB_SERVER_URL -e GITHUB_API_URL -e GITHUB_GRAPHQL_URL -e GITHUB_WORKSPACE -e GITHUB_ACTION -e GITHUB_EVENT_PATH -e GITHUB_ACTION_REPOSITORY -e GITHUB_ACTION_REF -e GITHUB_PATH -e GITHUB_ENV -e RUNNER_OS -e RUNNER_TOOL_CACHE -e RUNNER_TEMP -e RUNNER_WORKSPACE -e ACTIONS_RUNTIME_URL -e ACTIONS_RUNTIME_TOKEN -e ACTIONS_CACHE_URL -e GITHUB_ACTIONS=true -e CI=true -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/_temp/_runner_file_commands":"/github/file_commands" -v "/home/runner/work/Org-Name/Repo-Name":"/github/workspace" 8a33c1:3ea4031e03954238a09053f19aed7a50
remote: Repository not found.
fatal: repository 'https://github.com/Org-Name/Repo-Name/' not found
This is my job:
bump-version:
needs:
- unit-test
- integration-test
name: 'Bump Version on main'
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- uses: actions-ecosystem/[email protected]
id: get-merged-pr
name: Get Merged Pull Request
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
- uses: actions-ecosystem/action-release-label@v1
id: release-label
if: ${{ github.event.pull_request.merged == true }}
with:
label_prefix: ''
labels: ${{ steps.get-merged-pr.labels }}
- uses: actions-ecosystem/action-get-latest-tag@v1
id: get-latest-tag
if: ${{ steps.release-label.outputs.level != null }}
- uses: actions-ecosystem/action-bump-semver@v1
id: bump-semver
if: ${{ steps.release-label.outputs.level != null }}
with:
current_version: ${{ steps.get-latest-tag.outputs.tag }}
level: ${{ steps.release-label.outputs.level }}
- uses: actions-ecosystem/action-push-tag@v1
if: ${{ steps.release-label.outputs.level != null }}
with:
tag: ${{ steps.bump-semver.outputs.new_version }}
message: '${{ steps.bump-semver.outputs.new_version }}: PR (#${{ github.event.pull_request.number }}) ${{ github.git-merged-pr.title }}'
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.