From 0e75a5eb398096bb8eebc26113611425409be21a Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Thu, 5 Jun 2025 13:07:32 +0530 Subject: [PATCH 01/22] adding workflow files --- .github/auto-sync/PR_BODY.md | 8 +++++ .github/auto-sync/sync-test-output.txt | 0 .github/workflows/configlet-sync.yml | 46 ++++++++++++++++++++++++++ 3 files changed, 54 insertions(+) create mode 100644 .github/auto-sync/PR_BODY.md create mode 100644 .github/auto-sync/sync-test-output.txt create mode 100644 .github/workflows/configlet-sync.yml diff --git a/.github/auto-sync/PR_BODY.md b/.github/auto-sync/PR_BODY.md new file mode 100644 index 000000000..b1fa9034d --- /dev/null +++ b/.github/auto-sync/PR_BODY.md @@ -0,0 +1,8 @@ +This PR was generated automatically by a scheduled workflow. + +It includes updates from `configlet sync` for: +- 📄 Documentation +- 🧭 Metadata +- 🗂️ Filepaths + +Please review and merge if everything looks good! diff --git a/.github/auto-sync/sync-test-output.txt b/.github/auto-sync/sync-test-output.txt new file mode 100644 index 000000000..e69de29bb diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml new file mode 100644 index 000000000..325302f6f --- /dev/null +++ b/.github/workflows/configlet-sync.yml @@ -0,0 +1,46 @@ +name: Configlet Auto Sync + +on: + workflow_dispatch: + schedule: + - cron: '0 0 1,15 * *' + +jobs: + configlet-auto-sync: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Fetch configlet + run: ./bin/fetch-configlet + + - name: Run configlet sync for files + run: ./bin/configlet sync --docs --metadata --filepaths -u -y + + - name: Create pull request if changes + uses: peter-evans/create-pull-request@v5 + with: + token: ${{ secrets.GITHUB_TOKEN }} + commit-message: "🤖 Auto-sync docs, metadata, and filepaths" + title: "🤖 Configlet sync: docs, metadata, and filepaths" + body-path: .github/auto-sync/PR_BODY.md + branch: configlet-auto-sync + delete-branch: true + + - name: Run configlet sync for test and capture output + id: sync_test + run: | + ./bin/configlet sync --test | tee .github/auto-sync/sync-test-output.txt + echo "output<> $GITHUB_OUTPUT + cat .github/auto-sync/sync-test-output.txt >> $GITHUB_OUTPUT + echo "EOF" >> $GITHUB_OUTPUT + + - name: Create issue if tests are not synced + if: ${{ !contains(steps.sync_test.outputs.output, 'Every exercise has up-to-date tests!') }} + uses: peter-evans/create-issue-from-file@v4 + with: + token: ${{ secrets.GITHUB_TOKEN }} + title: "🚨 configlet sync --test found unsynced tests" + content-filepath: .github/auto-sync/sync-test-output.txt From 8d03422f3c9632f03716e8c8773b5a0da813e57a Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Thu, 5 Jun 2025 18:31:48 +0530 Subject: [PATCH 02/22] Update .github/workflows/configlet-sync.yml Co-authored-by: Kah Goh --- .github/workflows/configlet-sync.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index 325302f6f..a23e52be6 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -3,7 +3,7 @@ name: Configlet Auto Sync on: workflow_dispatch: schedule: - - cron: '0 0 1,15 * *' + - cron: '0 0 15 * *' jobs: configlet-auto-sync: From 0f84382af6dcd0c95fee2f12d8ec2050e5c70310 Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sat, 7 Jun 2025 18:19:45 +0530 Subject: [PATCH 03/22] Update configlet-sync.yml to fix the command for tests --- .github/workflows/configlet-sync.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index a23e52be6..f2c6f8442 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -32,7 +32,7 @@ jobs: - name: Run configlet sync for test and capture output id: sync_test run: | - ./bin/configlet sync --test | tee .github/auto-sync/sync-test-output.txt + ./bin/configlet sync --tests | tee .github/auto-sync/sync-test-output.txt echo "output<> $GITHUB_OUTPUT cat .github/auto-sync/sync-test-output.txt >> $GITHUB_OUTPUT echo "EOF" >> $GITHUB_OUTPUT From 4bc9381968cc70167bdb2b7e7faf30dfc84ad152 Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sat, 7 Jun 2025 18:48:01 +0530 Subject: [PATCH 04/22] Update configlet-sync.yml to ensure no duplicate issues are opened --- .github/workflows/configlet-sync.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index f2c6f8442..6894368b8 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -44,3 +44,4 @@ jobs: token: ${{ secrets.GITHUB_TOKEN }} title: "🚨 configlet sync --test found unsynced tests" content-filepath: .github/auto-sync/sync-test-output.txt + unique: true From 14e89a1d37895b9af048c97317903ad7d567dc38 Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sun, 8 Jun 2025 15:20:51 +0530 Subject: [PATCH 05/22] Refactoring yml workflow for tests --- .github/workflows/configlet-sync.yml | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index 6894368b8..508c072fc 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -29,19 +29,18 @@ jobs: branch: configlet-auto-sync delete-branch: true - - name: Run configlet sync for test and capture output + - name: Run configlet sync for tests id: sync_test run: | - ./bin/configlet sync --tests | tee .github/auto-sync/sync-test-output.txt echo "output<> $GITHUB_OUTPUT - cat .github/auto-sync/sync-test-output.txt >> $GITHUB_OUTPUT + ./bin/configlet sync --tests >> $GITHUB_OUTPUT echo "EOF" >> $GITHUB_OUTPUT - name: Create issue if tests are not synced if: ${{ !contains(steps.sync_test.outputs.output, 'Every exercise has up-to-date tests!') }} - uses: peter-evans/create-issue-from-file@v4 + uses: peter-evans/create-issue@v5 with: token: ${{ secrets.GITHUB_TOKEN }} - title: "🚨 configlet sync --test found unsynced tests" - content-filepath: .github/auto-sync/sync-test-output.txt - unique: true + title: "🚨 configlet sync --tests found unsynced tests" + body: ${{ steps.sync_test.outputs.output }} + update-existing: true From 7730a50a5667d9cc4a8d22f373e354801b7f534d Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sun, 8 Jun 2025 15:37:14 +0530 Subject: [PATCH 06/22] Removing line causing error --- .github/workflows/configlet-sync.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index 6894368b8..f2c6f8442 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -44,4 +44,3 @@ jobs: token: ${{ secrets.GITHUB_TOKEN }} title: "🚨 configlet sync --test found unsynced tests" content-filepath: .github/auto-sync/sync-test-output.txt - unique: true From 527450f8bd1ec1a86978cc0486583a5bdfaccdd5 Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sun, 8 Jun 2025 15:46:08 +0530 Subject: [PATCH 07/22] Updating sync test --- .github/workflows/configlet-sync.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index f2c6f8442..39e1939ee 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -32,11 +32,12 @@ jobs: - name: Run configlet sync for test and capture output id: sync_test run: | - ./bin/configlet sync --tests | tee .github/auto-sync/sync-test-output.txt + mkdir -p .github/auto-sync + output="$(./bin/configlet sync --tests | tee .github/auto-sync/sync-test-output.txt)" echo "output<> $GITHUB_OUTPUT - cat .github/auto-sync/sync-test-output.txt >> $GITHUB_OUTPUT + echo "$output" >> $GITHUB_OUTPUT echo "EOF" >> $GITHUB_OUTPUT - + - name: Create issue if tests are not synced if: ${{ !contains(steps.sync_test.outputs.output, 'Every exercise has up-to-date tests!') }} uses: peter-evans/create-issue-from-file@v4 From 6cbcf914dcc984735e74fb59bbf17a33639f5450 Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sun, 8 Jun 2025 15:49:02 +0530 Subject: [PATCH 08/22] Updating sync test --- .github/workflows/configlet-sync.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index 611c6846e..c41f5d750 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -29,11 +29,13 @@ jobs: branch: configlet-auto-sync delete-branch: true - - name: Run configlet sync for tests + - name: Run configlet sync for test and capture output id: sync_test run: | + mkdir -p .github/auto-sync + output="$(./bin/configlet sync --tests | tee .github/auto-sync/sync-test-output.txt)" echo "output<> $GITHUB_OUTPUT - ./bin/configlet sync --tests >> $GITHUB_OUTPUT + echo "$output" >> $GITHUB_OUTPUT echo "EOF" >> $GITHUB_OUTPUT - name: Create issue if tests are not synced From 4491143951ae4196d6b3a806e0b86984ecab1aca Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sun, 8 Jun 2025 15:54:26 +0530 Subject: [PATCH 09/22] Updating workflow file to print body od the issue --- .github/workflows/configlet-sync.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index c41f5d750..fd5f55136 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -34,10 +34,12 @@ jobs: run: | mkdir -p .github/auto-sync output="$(./bin/configlet sync --tests | tee .github/auto-sync/sync-test-output.txt)" + echo "configlet output:" + echo "$output" echo "output<> $GITHUB_OUTPUT echo "$output" >> $GITHUB_OUTPUT echo "EOF" >> $GITHUB_OUTPUT - + - name: Create issue if tests are not synced if: ${{ !contains(steps.sync_test.outputs.output, 'Every exercise has up-to-date tests!') }} uses: peter-evans/create-issue-from-file@v4 From 1f942d8c9da3bbc628110875a5b4f7f562991178 Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sun, 8 Jun 2025 16:36:56 +0530 Subject: [PATCH 10/22] Adding GitHub API integration to ensure no duplicate issues are opened --- .github/workflows/configlet-sync.yml | 31 ++++++++++++++++++++++------ 1 file changed, 25 insertions(+), 6 deletions(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index fd5f55136..8aa3e1083 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -36,15 +36,34 @@ jobs: output="$(./bin/configlet sync --tests | tee .github/auto-sync/sync-test-output.txt)" echo "configlet output:" echo "$output" - echo "output<> $GITHUB_OUTPUT - echo "$output" >> $GITHUB_OUTPUT - echo "EOF" >> $GITHUB_OUTPUT - - - name: Create issue if tests are not synced + echo "output<> "$GITHUB_OUTPUT" + echo "$output" >> "$GITHUB_OUTPUT" + echo "EOF" >> "$GITHUB_OUTPUT" + + - name: Find existing issue for test sync + id: find_issue + if: ${{ !contains(steps.sync_test.outputs.output, 'Every exercise has up-to-date tests!') }} + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + ISSUE_TITLE="🚨 configlet sync --test found unsynced tests" + ISSUE_DATA=$(gh issue list --search "is:issue is:open in:title \"${ISSUE_TITLE}\" repo:${{ github.repository }}" --json number,title --jq '.[0]') + + if [ -z "$ISSUE_DATA" ]; then + echo "No open issue found with title: '${ISSUE_TITLE}'. A new one will be created." + echo "issue_number=" >> $GITHUB_OUTPUT + else + ISSUE_NUMBER=$(echo "$ISSUE_DATA" | jq -r '.number') + echo "Found existing issue number: $ISSUE_NUMBER for title: '$ISSUE_TITLE'" + echo "issue_number=$ISSUE_NUMBER" >> $GITHUB_OUTPUT + fi + + - name: Create or Update issue if tests are not synced if: ${{ !contains(steps.sync_test.outputs.output, 'Every exercise has up-to-date tests!') }} - uses: peter-evans/create-issue-from-file@v4 + uses: peter-evans/create-issue-from-file@v5 with: token: ${{ secrets.GITHUB_TOKEN }} title: "🚨 configlet sync --test found unsynced tests" content-filepath: .github/auto-sync/sync-test-output.txt + issue-number: ${{ steps.find_issue.outputs.issue_number || '' }} \ No newline at end of file From 5a8b785b17062d1c09f70871178bc45b05f24204 Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sun, 8 Jun 2025 16:59:56 +0530 Subject: [PATCH 11/22] Adding backticks in issue content --- .github/workflows/configlet-sync.yml | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index 8aa3e1083..2b2a019c9 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -33,11 +33,17 @@ jobs: id: sync_test run: | mkdir -p .github/auto-sync - output="$(./bin/configlet sync --tests | tee .github/auto-sync/sync-test-output.txt)" + configlet_raw_output="$(./bin/configlet sync --tests)" + echo "configlet output:" - echo "$output" + echo "$configlet_raw_output" + + echo '```' > .github/auto-sync/sync-test-output.txt + echo "$configlet_raw_output" >> .github/auto-sync/sync-test-output.txt + echo '```' >> .github/auto-sync/sync-test-output.txt + echo "output<> "$GITHUB_OUTPUT" - echo "$output" >> "$GITHUB_OUTPUT" + echo "$configlet_raw_output" >> "$GITHUB_OUTPUT" echo "EOF" >> "$GITHUB_OUTPUT" - name: Find existing issue for test sync @@ -66,4 +72,3 @@ jobs: title: "🚨 configlet sync --test found unsynced tests" content-filepath: .github/auto-sync/sync-test-output.txt issue-number: ${{ steps.find_issue.outputs.issue_number || '' }} - \ No newline at end of file From 84f26197f7a2abf1c28453b54af6e1055f9b6faa Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sun, 8 Jun 2025 17:04:13 +0530 Subject: [PATCH 12/22] Removing unnecesarry mkdir command --- .github/workflows/configlet-sync.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index 2b2a019c9..fd550f847 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -32,7 +32,6 @@ jobs: - name: Run configlet sync for test and capture output id: sync_test run: | - mkdir -p .github/auto-sync configlet_raw_output="$(./bin/configlet sync --tests)" echo "configlet output:" From 82da5d02d0b3f50669ce3d08a376cdb64e6f2e1d Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sun, 8 Jun 2025 17:10:42 +0530 Subject: [PATCH 13/22] Adding tests command --- .github/workflows/configlet-sync.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index fd550f847..14bc1921c 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -32,7 +32,8 @@ jobs: - name: Run configlet sync for test and capture output id: sync_test run: | - configlet_raw_output="$(./bin/configlet sync --tests)" + mkdir -p .github/auto-sync + output="$(./bin/configlet sync --tests | tee .github/auto-sync/sync-test-output.txt)" echo "configlet output:" echo "$configlet_raw_output" From b76a63070687499e1513f59df56a2732655e466e Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sun, 8 Jun 2025 17:14:49 +0530 Subject: [PATCH 14/22] variable name mismatch --- .github/workflows/configlet-sync.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index 14bc1921c..3ddd40cee 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -33,7 +33,7 @@ jobs: id: sync_test run: | mkdir -p .github/auto-sync - output="$(./bin/configlet sync --tests | tee .github/auto-sync/sync-test-output.txt)" + configlet_raw_output="$(./bin/configlet sync --tests | tee .github/auto-sync/sync-test-output.txt)" echo "configlet output:" echo "$configlet_raw_output" From ab090e788210358c9f9f6d8d6382f3383b9703e8 Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Fri, 13 Jun 2025 20:39:18 +0530 Subject: [PATCH 15/22] Refactoring workflow into two different jobs and adding option to not execute the second --- .github/workflows/configlet-sync.yml | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index 3ddd40cee..9a6e21088 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -5,8 +5,11 @@ on: schedule: - cron: '0 0 15 * *' +env: + EXECUTE_SECOND_JOB: true # Change to false to disable the second job + jobs: - configlet-auto-sync: + sync-docs-metadata: runs-on: ubuntu-latest steps: @@ -29,6 +32,25 @@ jobs: branch: configlet-auto-sync delete-branch: true + check-test-sync: + runs-on: ubuntu-latest + needs: sync-docs-metadata + + steps: + - name: Check if second job should run + run: | + echo "EXECUTE_SECOND_JOB=${{ env.EXECUTE_SECOND_JOB }}" + if [[ "${{ env.EXECUTE_SECOND_JOB }}" != "true" ]]; then + echo "Skipping test sync job as EXECUTE_SECOND_JOB is not true" + exit 0 + fi + + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Fetch configlet + run: ./bin/fetch-configlet + - name: Run configlet sync for test and capture output id: sync_test run: | From 17754a0387af99f040c43370918b1fa5aa6e4bdf Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sat, 14 Jun 2025 07:47:58 +0530 Subject: [PATCH 16/22] removing env toggle for second job --- .github/workflows/configlet-sync.yml | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index 9a6e21088..2d3c4af68 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -5,9 +5,6 @@ on: schedule: - cron: '0 0 15 * *' -env: - EXECUTE_SECOND_JOB: true # Change to false to disable the second job - jobs: sync-docs-metadata: runs-on: ubuntu-latest @@ -37,14 +34,6 @@ jobs: needs: sync-docs-metadata steps: - - name: Check if second job should run - run: | - echo "EXECUTE_SECOND_JOB=${{ env.EXECUTE_SECOND_JOB }}" - if [[ "${{ env.EXECUTE_SECOND_JOB }}" != "true" ]]; then - echo "Skipping test sync job as EXECUTE_SECOND_JOB is not true" - exit 0 - fi - - name: Checkout repository uses: actions/checkout@v4 From 8f050cf0ea30f76e99f630423b205223e7ffafc6 Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sat, 14 Jun 2025 22:49:47 +0530 Subject: [PATCH 17/22] Removing dependency by replacing body-path by body --- .github/workflows/configlet-sync.yml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index 2d3c4af68..e32b12ad7 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -25,7 +25,15 @@ jobs: token: ${{ secrets.GITHUB_TOKEN }} commit-message: "🤖 Auto-sync docs, metadata, and filepaths" title: "🤖 Configlet sync: docs, metadata, and filepaths" - body-path: .github/auto-sync/PR_BODY.md + body: | + This PR was generated automatically by a scheduled workflow. + + It includes updates from `configlet sync` for: + - 📄 Documentation + - 🧭 Metadata + - 🗂️ Filepaths + + Please review and merge if everything looks good! branch: configlet-auto-sync delete-branch: true From d7f6607d8056b111d24b4536ef6206ee82c15792 Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sat, 14 Jun 2025 22:57:52 +0530 Subject: [PATCH 18/22] Removing dependency by removing auto-sync dir and its usage --- .github/auto-sync/PR_BODY.md | 8 -------- .github/auto-sync/sync-test-output.txt | 0 .github/workflows/configlet-sync.yml | 11 +++++------ 3 files changed, 5 insertions(+), 14 deletions(-) delete mode 100644 .github/auto-sync/PR_BODY.md delete mode 100644 .github/auto-sync/sync-test-output.txt diff --git a/.github/auto-sync/PR_BODY.md b/.github/auto-sync/PR_BODY.md deleted file mode 100644 index b1fa9034d..000000000 --- a/.github/auto-sync/PR_BODY.md +++ /dev/null @@ -1,8 +0,0 @@ -This PR was generated automatically by a scheduled workflow. - -It includes updates from `configlet sync` for: -- 📄 Documentation -- 🧭 Metadata -- 🗂️ Filepaths - -Please review and merge if everything looks good! diff --git a/.github/auto-sync/sync-test-output.txt b/.github/auto-sync/sync-test-output.txt deleted file mode 100644 index e69de29bb..000000000 diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index e32b12ad7..64dd0178c 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -51,15 +51,14 @@ jobs: - name: Run configlet sync for test and capture output id: sync_test run: | - mkdir -p .github/auto-sync - configlet_raw_output="$(./bin/configlet sync --tests | tee .github/auto-sync/sync-test-output.txt)" + configlet_raw_output="$(./bin/configlet sync --tests | tee .github/sync-test-output.txt)" echo "configlet output:" echo "$configlet_raw_output" - echo '```' > .github/auto-sync/sync-test-output.txt - echo "$configlet_raw_output" >> .github/auto-sync/sync-test-output.txt - echo '```' >> .github/auto-sync/sync-test-output.txt + echo '```' > .github/sync-test-output.txt + echo "$configlet_raw_output" >> .github/sync-test-output.txt + echo '```' >> .github/sync-test-output.txt echo "output<> "$GITHUB_OUTPUT" echo "$configlet_raw_output" >> "$GITHUB_OUTPUT" @@ -89,5 +88,5 @@ jobs: with: token: ${{ secrets.GITHUB_TOKEN }} title: "🚨 configlet sync --test found unsynced tests" - content-filepath: .github/auto-sync/sync-test-output.txt + content-filepath: .github/sync-test-output.txt issue-number: ${{ steps.find_issue.outputs.issue_number || '' }} From 4e7efff96c9a109f65c9af96d261394d7e3e3a71 Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Sat, 14 Jun 2025 23:00:26 +0530 Subject: [PATCH 19/22] Removing needs statement --- .github/workflows/configlet-sync.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index 64dd0178c..562682f00 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -39,7 +39,6 @@ jobs: check-test-sync: runs-on: ubuntu-latest - needs: sync-docs-metadata steps: - name: Checkout repository From d1f3dec6399f7b32ce3e205086d4224903971992 Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Mon, 16 Jun 2025 20:19:47 +0530 Subject: [PATCH 20/22] Adding timeout (best GHA practice documentation) --- .github/workflows/configlet-sync.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index 562682f00..549bc1184 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -7,6 +7,7 @@ on: jobs: sync-docs-metadata: + timeout-minutes: 30 runs-on: ubuntu-latest steps: @@ -38,6 +39,7 @@ jobs: delete-branch: true check-test-sync: + timeout-minutes: 30 runs-on: ubuntu-latest steps: From 02435d1669aa64b5692034d1bf34e160d033f4e8 Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Mon, 16 Jun 2025 20:21:14 +0530 Subject: [PATCH 21/22] Reducing timeout minutes --- .github/workflows/configlet-sync.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index 549bc1184..bdd0ff774 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -7,7 +7,7 @@ on: jobs: sync-docs-metadata: - timeout-minutes: 30 + timeout-minutes: 10 runs-on: ubuntu-latest steps: @@ -39,7 +39,7 @@ jobs: delete-branch: true check-test-sync: - timeout-minutes: 30 + timeout-minutes: 10 runs-on: ubuntu-latest steps: From dc8e4eb67294dfcb2cb36c4d897b7d2a93518686 Mon Sep 17 00:00:00 2001 From: Jagdish Prajapati Date: Mon, 16 Jun 2025 20:24:31 +0530 Subject: [PATCH 22/22] Pinning test runner version (best GHA practice documentation) --- .github/workflows/configlet-sync.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/configlet-sync.yml b/.github/workflows/configlet-sync.yml index bdd0ff774..6373e5d24 100644 --- a/.github/workflows/configlet-sync.yml +++ b/.github/workflows/configlet-sync.yml @@ -8,7 +8,7 @@ on: jobs: sync-docs-metadata: timeout-minutes: 10 - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 steps: - name: Checkout repository @@ -40,7 +40,7 @@ jobs: check-test-sync: timeout-minutes: 10 - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 steps: - name: Checkout repository