diff --git a/.github/prompts/review/03-self-improvement.md b/.github/prompts/review/03-self-improvement.md index f8e550d..6de8f9f 100644 --- a/.github/prompts/review/03-self-improvement.md +++ b/.github/prompts/review/03-self-improvement.md @@ -14,11 +14,11 @@ Both types of prompts can be improved through issue creation. Use the appropriate channel for different types of feedback: -| Channel | When to Use | Example | -|---------|-------------|---------| -| **PR Review** | Code/issues in the current PR's changes | "Line 42 has a bug" | -| **PR Issue Comment** | Meta-feedback about the PR or process | "This PR needs tests" | -| **Separate Issue** | Prompt improvements beyond current PR | "Add security guidelines" | +| Channel | When to Use | Example | +| -------------------- | --------------------------------------- | ------------------------- | +| **PR Review** | Code/issues in the current PR's changes | "Line 42 has a bug" | +| **PR Issue Comment** | Meta-feedback about the PR or process | "This PR needs tests" | +| **Separate Issue** | Prompt improvements beyond current PR | "Add security guidelines" | **Key distinction:** Feedback about the PR's code goes in the review. Feedback about prompts goes in a separate issue. Do not mix these. diff --git a/.github/workflows/bidirectional-sync.yml b/.github/workflows/bidirectional-sync.yml index 2da6df6..4fc7685 100644 --- a/.github/workflows/bidirectional-sync.yml +++ b/.github/workflows/bidirectional-sync.yml @@ -31,18 +31,20 @@ jobs: fi - name: Verify required configuration + env: + SYNC_PRIVATE_KEY: ${{ secrets.SYNC_PRIVATE_KEY }} + APP_ID: ${{ steps.repo.outputs.app_id }} run: | - if [[ -z "${{ secrets.SYNC_PRIVATE_KEY }}" ]]; then + if [[ -z "$SYNC_PRIVATE_KEY" ]]; then echo "::error::SYNC_PRIVATE_KEY secret is not set. Please configure it in repo settings." exit 1 fi - if [[ -z "${{ steps.repo.outputs.app_id }}" ]]; then + if [[ -z "$APP_ID" ]]; then echo "::error::GitHub App ID variable not set. Configure EXADEV_APP_ID or ADPEAK_APP_ID." exit 1 fi - name: Generate GitHub App token for other repo - if: steps.check.outputs.skip != 'true' uses: tibdex/github-app-token@v2 id: token with: @@ -51,7 +53,6 @@ jobs: - name: Sync to other repo id: sync - if: steps.check.outputs.skip != 'true' env: TARGET_REPO: ${{ steps.repo.outputs.target }} TARGET_TOKEN: ${{ steps.token.outputs.token }} @@ -84,8 +85,8 @@ jobs: git config user.email "github-actions[bot]@users.noreply.github.com" if git rebase target/main 2>/dev/null; then - # Rebase successful - push directly to main - git push target HEAD:main + # Rebase successful - push with ci.skip to prevent triggering workflow loop + git push target HEAD:main -o ci.skip echo "skip_pr=true" >> "$GITHUB_OUTPUT" echo "::notice::Successfully rebased and synced ${COMMITS_BEHIND} commit(s) to ${TARGET_REPO}" else diff --git a/.husky/post-rewrite b/.husky/post-rewrite new file mode 100755 index 0000000..f010a4a --- /dev/null +++ b/.husky/post-rewrite @@ -0,0 +1,4 @@ +#!/bin/sh +# Run lint-staged after git commit --amend or rebase +# This catches formatting issues that pre-commit missed +npx lint-staged