This repository was archived by the owner on Nov 1, 2025. It is now read-only.
Update Inkeep Packages #29
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Update Inkeep Packages | |
| on: | |
| schedule: | |
| # Run every day at 9 AM PT | |
| - cron: "0 16 * * *" | |
| workflow_dispatch: # Allow manual trigger | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| jobs: | |
| update-packages: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v4 | |
| with: | |
| version: 10.10.0 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: "22" | |
| cache: "pnpm" | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Check for updates | |
| id: check-updates | |
| run: | | |
| # Check for outdated @inkeep packages | |
| OUTDATED=$(pnpm outdated --filter '@inkeep/*' --format json || echo "[]") | |
| # Check if there are any outdated packages | |
| if [ "$OUTDATED" = "[]" ] || [ -z "$OUTDATED" ]; then | |
| echo "has_updates=false" >> $GITHUB_OUTPUT | |
| echo "No @inkeep package updates available" | |
| else | |
| echo "has_updates=true" >> $GITHUB_OUTPUT | |
| echo "Updates available:" | |
| echo "$OUTDATED" | jq '.' | |
| # Extract package names and versions for PR body | |
| PACKAGE_INFO=$(echo "$OUTDATED" | jq -r '.[] | "- `\(.packageName)`: \(.current) → \(.latest)"') | |
| echo "package_info<<EOF" >> $GITHUB_OUTPUT | |
| echo "$PACKAGE_INFO" >> $GITHUB_OUTPUT | |
| echo "EOF" >> $GITHUB_OUTPUT | |
| fi | |
| - name: Update @inkeep packages | |
| if: steps.check-updates.outputs.has_updates == 'true' | |
| run: | | |
| # Update all @inkeep packages to latest | |
| pnpm update '@inkeep/*' --latest --recursive | |
| - name: Get package versions | |
| if: steps.check-updates.outputs.has_updates == 'true' | |
| id: versions | |
| run: | | |
| VERSIONS=$(jq -r '.dependencies | to_entries[] | select(.key | startswith("@inkeep/")) | "- \(.key): \(.value)"' package.json) | |
| echo "versions<<EOF" >> $GITHUB_OUTPUT | |
| echo "$VERSIONS" >> $GITHUB_OUTPUT | |
| echo "EOF" >> $GITHUB_OUTPUT | |
| - name: Create Pull Request | |
| if: steps.check-updates.outputs.has_updates == 'true' | |
| uses: peter-evans/create-pull-request@v6 | |
| with: | |
| token: ${{ secrets.GITHUB_TOKEN }} | |
| commit-message: "chore(deps): update @inkeep packages" | |
| title: "chore(deps): Update @inkeep packages" | |
| body: | | |
| ## 📦 @inkeep Package Updates | |
| This PR updates @inkeep packages to their latest versions. | |
| ### Updated Packages | |
| ${{ steps.check-updates.outputs.package_info }} | |
| ### Current Versions | |
| ${{ steps.versions.outputs.versions }} | |
| --- | |
| 🤖 This PR was automatically generated by the Update Inkeep Packages workflow. | |
| Please review the changelogs for each package before merging: | |
| - Check the [changesets releases](https://github.com/inkeep/inkeep-packages/releases) for detailed changelog information | |
| branch: update-inkeep-packages | |
| delete-branch: true | |
| labels: | | |
| dependencies | |
| inkeep-packages | |
| automated | |
| draft: false |