update-main-version.yml 876 B

1234567891011121314151617181920212223242526272829303132
  1. name: Update Main Version
  2. run-name: Move ${{ github.event.inputs.major_version }} to ${{ github.event.inputs.target }}
  3. on:
  4. workflow_dispatch:
  5. inputs:
  6. target:
  7. description: The tag or reference to use
  8. required: true
  9. major_version:
  10. type: choice
  11. description: The major version to update
  12. options:
  13. - v4
  14. - v3
  15. - v2
  16. jobs:
  17. tag:
  18. runs-on: ubuntu-latest
  19. steps:
  20. - uses: actions/checkout@v3
  21. with:
  22. fetch-depth: 0
  23. - name: Git config
  24. run: |
  25. git config user.name github-actions
  26. git config user.email github-actions@github.com
  27. - name: Tag new target
  28. run: git tag -f ${{ github.event.inputs.major_version }} ${{ github.event.inputs.target }}
  29. - name: Push new tag
  30. run: git push origin ${{ github.event.inputs.major_version }} --force