Skip to content

feat: code operation messages #22

feat: code operation messages

feat: code operation messages #22

Workflow file for this run

name: Update Protobuf Docs
on:
push:
branches:
- main
permissions:
contents: write
jobs:
update-wiki:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up Java
uses: actions/setup-java@v3
with:
distribution: temurin
java-version: '17'
- name: Generate proto docs
run: ./gradlew generateProto
- name: Checkout Wiki
uses: actions/checkout@v3
with:
repository: ${{ github.repository }}.wiki.git
path: wiki
ref: master
token: ${{ secrets.GITHUB_TOKEN }}
fetch-depth: 0
- name: Copy generated wiki
run: |
mkdir -p wiki
cp build/generated/sources/proto/main/doc/proto.md wiki/Proto.md
- name: Update Wiki
working-directory: wiki
run: |
git config user.name "${{ github.event.head_commit.committer.name }}"
git config user.email "github-actions[bot]@users.noreply.github.com"
git add Proto.md
if ! git diff --cached --quiet; then
git commit -m "${{ github.event.head_commit.message }}"
git push origin HEAD:master
else
echo "No changes to commit"
fi