Merged dev into main #42
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
name: Trig suibase-api-docs refresh | |
on: | |
push: | |
branches: [main] | |
workflow_dispatch: | |
jobs: | |
diff: | |
runs-on: [ubuntu-latest] | |
outputs: | |
isDocHelperAPI: ${{ steps.diff.outputs.isDocHelperAPI }} | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.ref }} | |
- name: Detect Changes | |
uses: "./.github/actions/diffs" | |
id: diff | |
with: | |
ref: ${{ github.ref }} | |
- name: Upload Trigger Artifact | |
if: ${{ steps.diff.outputs.isDocHelperAPI == 'true' }} | |
uses: actions/upload-artifact@v4 | |
with: | |
name: CHANGELOG.md | |
path: ./CHANGELOG.md | |
if-no-files-found: error | |
retention-days: 1 | |
trig: | |
needs: diff | |
if: ${{ (needs.diff.outputs.isDocHelperAPI == 'true') || (github.event_name == 'workflow_dispatch') }} | |
runs-on: ubuntu-latest | |
steps: | |
- name: Download Trigger Artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: CHANGELOG.md | |
path: . | |
- name: Push CHANGELOG.md to trigger other repos | |
uses: dmnemec/copy_file_to_another_repo_action@main | |
env: | |
API_TOKEN_GITHUB: ${{ secrets.SUIBASE_API_DOC_TOKEN }} | |
with: | |
source_file: "CHANGELOG.md" | |
destination_repo: "chainmovers/suibase-api-docs" | |
destination_folder: "." | |
user_email: "[email protected]" | |
user_name: "Mario Fortier" |