diff --git a/.github/actions/publish-docs/action.yml b/.github/actions/publish-docs/action.yml deleted file mode 100644 index a95dec35e..000000000 --- a/.github/actions/publish-docs/action.yml +++ /dev/null @@ -1,41 +0,0 @@ -name: Publish API Docs -description: Builds and publishes the API documentation to Google Cloud Storage -inputs: - # The path to the directory containing the API documentation - docs_path: - description: 'The path to the directory containing the API documentation' - required: true - default: '/docs/' - # The destination path in Google Cloud Storage - destination_path: - description: 'The destination path in Google Cloud Storage' - required: true - # The Google Cloud Storage bucket to upload the documentation to - bucket: - description: 'The Google Cloud Storage bucket to upload the documentation to' - required: true - # The Google Cloud Storage bucket to upload the documentation to - credentials_json: - description: 'The Google Cloud Storage bucket to upload the documentation to' - required: true - -runs: - using: composite - steps: - - name: Checkout - uses: actions/checkout@v4 - - - name: Build documentation - run: npx typedoc - shell: bash - - - name: Authenticate - uses: 'google-github-actions/auth@v2' - with: - credentials_json: ${{ inputs.credentials_json }} - - - name: Upload documentation - uses: 'google-github-actions/upload-cloud-storage@v2' - with: - path: ${{ inputs.docs_path }} - destination: "${{ inputs.bucket }}/${{ inputs.destination_path }}" diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index b7d95c4d2..1a8b35a06 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -46,21 +46,26 @@ jobs: # NPM_DRY_RUN: false # NPM_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }} - - name: Upload API Docs - uses: ./.github/actions/publish-docs + - name: Build documentation + run: npx typedoc + shell: bash + + - name: Authenticate + uses: 'google-github-actions/auth@v2' with: - docs_path: './docs/' - destination_path: "player/ui/${{ steps.extract-version.outputs.packageJsonVersion }}/" - bucket: ${{ secrets.GCS_BUCKET }} credentials_json: ${{ secrets.GCS_CREDENTIALS }} - - name: Upload API Docs for major version - uses: ./.github/actions/publish-docs + - name: Upload docs + uses: 'google-github-actions/upload-cloud-storage@v2' with: - docs_path: './docs/' - destination_path: 'player/ui/3/' - bucket: ${{ secrets.GCS_BUCKET }} - credentials_json: ${{ secrets.GCS_CREDENTIALS }} + path: './docs/' + destination: "${{ secrets.GCS_BUCKET }}/player/ui/${{ steps.extract-version.outputs.packageJsonVersion }}" + + - name: Upload docs for major version + uses: 'google-github-actions/upload-cloud-storage@v2' + with: + path: './docs/' + destination: "${{ secrets.GCS_BUCKET }}/player/ui/3" # - name: Notify team # run: node .github/scripts/notifySlackTeam.js 'success' 'CHANGELOG.md' ${{ secrets.RELEASE_SUCCESS_SLACK_WEBHOOK }}