-
Notifications
You must be signed in to change notification settings - Fork 45
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
13 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,9 @@ name: Update Docs Version | |
on: | ||
repository_dispatch: | ||
types: [update-version] | ||
push: | ||
branches: | ||
- fix_dispatch_trigger | ||
|
||
jobs: | ||
update-docs-version: | ||
|
@@ -14,6 +17,14 @@ jobs: | |
- name: Extract tag name | ||
run: echo "TAG_NAME=${{ github.event.client_payload.tag }}" >> $GITHUB_ENV | ||
|
||
- name: Set up Git user identity | ||
run: | | ||
git config --global user.name "obol-platform" | ||
git config --global user.email "[email protected]" | ||
- name: Set TAG_NAME environment variable | ||
run: echo "TAG_NAME=v1.1.3" >> $GITHUB_ENV | ||
|
||
- name: Update docs to new version | ||
run: | | ||
TAG_NAME="$(echo "${TAG_NAME}" | sed 's/^v//')" | ||
|
@@ -44,7 +55,7 @@ jobs: | |
uses: peter-evans/create-pull-request@v5 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
base: main | ||
head: update-version-${{ env.TAG_NAME }} | ||
branch: update-version-${{ env.TAG_NAME }} | ||
delete-branch: true | ||
title: "Update docs to use version v${TAG_NAME}" | ||
body: "Automatically generated PR to update documentation for version v${TAG_NAME}" |