From cb258702793a2460bc922862f5aae1b5999e3806 Mon Sep 17 00:00:00 2001 From: Joe Corall Date: Wed, 4 Dec 2024 14:35:21 -0500 Subject: [PATCH] test gha --- .github/workflows/run.yml | 64 --------------------------------------- 1 file changed, 64 deletions(-) diff --git a/.github/workflows/run.yml b/.github/workflows/run.yml index a371b4c..b7cfb8c 100644 --- a/.github/workflows/run.yml +++ b/.github/workflows/run.yml @@ -45,72 +45,8 @@ jobs: token_format: 'access_token' access_token_scopes: "https://www.googleapis.com/auth/spreadsheets" - - name: Get Job ID from GH API - id: get-job-id - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: | - jobs=$(gh api repos/${{ github.repository }}/actions/runs/${{ github.run_id}}/attempts/${{ github.run_attempt }}/jobs) - job_id=$(echo $jobs | jq -r '.jobs[] | select(.runner_name=="${{ runner.name }}") | .id') - echo "job_id=$job_id" >> $GITHUB_OUTPUT - - - name: query google - run: ./scripts/download.sh - env: - URL: ${{ github.event.inputs.url }} - RANGE: ${{ github.event.inputs.range }} - ACCESS_TOKEN: ${{ steps.auth.outputs.access_token }} - - - name: Notify Slack on Start - run: ./scripts/slack.sh - env: - SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} - MESSAGE: | - ${{ github.actor }} started workbench ingest for __TITLE__ - - Items being ingested: __LINE_COUNT__ - - Google Sheet: __URL__ - - Workbench execution log: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ steps.get-job-id.outputs.job_id }}#step:10:1 - URL: ${{ github.event.inputs.url }} - - - name: transform google sheet - run: ./scripts/transform.sh - env: - URL: ${{ github.event.inputs.url }} - RANGE: ${{ github.event.inputs.range }} - ACCESS_TOKEN: ${{ steps.auth.outputs.access_token }} - - - name: Checkout workbench - uses: actions/checkout@v4 - with: - repository: lehigh-university-libraries/islandora_workbench - ref: simple-field-json - path: islandora_workbench - - - name: execute - working-directory: islandora_workbench - run: ../scripts/run-workbench.sh - env: - ISLANDORA_WORKBENCH_PASSWORD: ${{ secrets.ISLANDORA_WORKBENCH_PASSWORD }} - - name: add node IDs to sheet run: ./scripts/insert-nids.sh env: URL: ${{ github.event.inputs.url }} ACCESS_TOKEN: ${{ steps.auth.outputs.access_token }} - - - name: Notify Slack on Success - if: ${{ success() }} - run: ./scripts/slack.sh - env: - SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} - MESSAGE: "✅ Workbench job succeeded!" - - - name: Notify Slack on Failure - if: ${{ failure() }} - run: ./scripts/slack.sh - env: - SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} - MESSAGE: "🚨 Workbench job failed!"