From 848c8855c468b938ed53cb80b237c44d26a75de6 Mon Sep 17 00:00:00 2001 From: sciencewhiz Date: Tue, 18 Jun 2024 18:54:43 -0700 Subject: [PATCH] Add action to tag on allwpilib tag dispatch Adapted from robotpy --- .github/workflows/bump.yml | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 .github/workflows/bump.yml diff --git a/.github/workflows/bump.yml b/.github/workflows/bump.yml new file mode 100644 index 0000000..3735a09 --- /dev/null +++ b/.github/workflows/bump.yml @@ -0,0 +1,23 @@ +--- +name: bump + +on: [repository_dispatch] + +jobs: + bump: + if: github.event_name == 'repository_dispatch' && github.event.action == 'tag' + runs-on: ubuntu-latest + steps: + - name: Information + run: | + echo "Version update for ${{ github.event.client_payload.package_name }} -> ${{ github.event.client_payload.package_version }} requested" + - uses: actions/checkout@v4 + with: + token: ${{ secrets.REPO_ACCESS_TOKEN }} + fetch-depth: 0 + + - name: Tag and push + shell: bash + run: | + git tag ${{ github.event.client_payload.package_version }} + git push origin ${{ github.event.client_payload.package_version }} \ No newline at end of file