Skip to content

Merge pull request #14 from settle-finance/workflow #17

Merge pull request #14 from settle-finance/workflow

Merge pull request #14 from settle-finance/workflow #17

Workflow file for this run

name: Tag and Release on Main Push
on:
push:
branches:
- main
jobs:
tag-and-release:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Set up Git credentials
run: |
git config --local user.email "[email protected]"
git config --local user.name "sharansalian"
- name: Get commit SHA
id: commit_sha
run: echo "${GITHUB_SHA::8}" # Extracts the first 8 characters of the commit SHA
- name: Create Tag and Release
run: |
git tag -a "v${{ steps.commit_sha.outputs.stdout }}" -m "Automated tag creation on main push"
git push origin "v${{ steps.commit_sha.outputs.stdout }}"
hub release create -m "Release v${{ steps.commit_sha.outputs.stdout }}" "v${{ steps.commit_sha.outputs.stdout }}"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}