also looking at this
fix(ci): enforce dependency update boundaries
#311
4 files
+163
-28
| @@ -26,7 +26,7 @@ on: | ||
| 26 | 26 | - dashboard |
| 27 | 27 | # Update job inputs |
| 28 | 28 | strategy: |
| 29 | description: Update strategy | |
| 29 | description: Patch only, minor plus patches, major only, or all stable versions; pinned refs require manual review | |
| 30 | 30 | required: false |
| 31 | 31 | default: patch |
| 32 | 32 | type: choice |
| @@ -292,33 +292,13 @@ jobs: | ||
| 292 | 292 | echo "Branch: $" |
| 293 | 293 | |
| 294 | 294 | - name: Run Buddy dependency updates |
| 295 | if: ${{ github.event.inputs.dry_run != 'true' }} | |
| 296 | run: | | |
| 297 | STRATEGY="$" | |
| 298 | PACKAGES="$" | |
| 299 | VERBOSE="$" | |
| 300 | ||
| 301 | echo "🚀 Running dependency updates..." | |
| 302 | echo "This will create/update PRs if outdated dependencies are found" | |
| 303 | echo "" | |
| 304 | ||
| 305 | set -e # Exit on any error | |
| 306 | ||
| 307 | if [ "$PACKAGES" != "" ]; then | |
| 308 | if [ "$VERBOSE" = "true" ]; then | |
| 309 | bunx buddy-bot update --packages "$PACKAGES" --verbose | |
| 310 | else | |
| 311 | bunx buddy-bot update --packages "$PACKAGES" | |
| 312 | fi | |
| 313 | else | |
| 314 | if [ "$VERBOSE" = "true" ]; then | |
| 315 | bunx buddy-bot update --strategy "$STRATEGY" --verbose | |
| 316 | else | |
| 317 | bunx buddy-bot update --strategy "$STRATEGY" | |
| 318 | fi | |
| 319 | fi | |
| 320 | ||
| 295 | run: bun scripts/buddy-update.ts | |
| 321 | 296 | env: |
| 297 | BUDDY_STRATEGY: ${{ github.event.inputs.strategy || 'patch' }} | |
| 298 | BUDDY_PACKAGES: ${{ github.event.inputs.packages }} | |
| 299 | BUDDY_DRY_RUN: ${{ github.event.inputs.dry_run || 'false' }} | |
| 300 | BUDDY_VERBOSE: ${{ github.event.inputs.verbose || 'true' }} | |
| 301 | BUDDY_BASE_BRANCH: ${{ github.event.repository.default_branch }} | |
| 322 | 302 | GITHUB_TOKEN: ${{ secrets.BUDDY_BOT_TOKEN || secrets.GITHUB_TOKEN }} |
| 323 | 303 | BUDDY_BOT_TOKEN: ${{ secrets.BUDDY_BOT_TOKEN }} |
| 324 | 304 | |