Update OpenTUI Dependencies #84
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 OpenTUI Dependencies | |
| on: | |
| schedule: | |
| # Run at 9:00 AM UTC | |
| - cron: "0 0 * * *" | |
| workflow_dispatch: | |
| # Allow manual triggering | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| jobs: | |
| update-dependencies: | |
| name: Update @opentui/* Dependencies | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Setup Bun | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version: latest | |
| - name: Install jq | |
| run: sudo apt-get update && sudo apt-get install -y jq | |
| - name: Make script executable | |
| run: chmod +x scripts/update-opentui-deps.sh | |
| - name: Check for @opentui/* updates | |
| id: check-updates | |
| run: | | |
| # Run the update script | |
| ./scripts/update-opentui-deps.sh | |
| # Check if any files were changed | |
| if git diff --quiet packages/templates; then | |
| echo "has-updates=false" >> $GITHUB_OUTPUT | |
| echo "No updates found" | |
| else | |
| echo "has-updates=true" >> $GITHUB_OUTPUT | |
| echo "Updates found" | |
| # Show what changed | |
| echo "Changed files:" | |
| git diff --name-only packages/templates | cat | |
| # Show the diff for package.json files | |
| echo "Changes:" | |
| git diff packages/templates | cat | |
| fi | |
| - name: Create Pull Request | |
| if: steps.check-updates.outputs.has-updates == 'true' | |
| uses: peter-evans/create-pull-request@v7 | |
| with: | |
| token: ${{ secrets.GITHUB_TOKEN }} | |
| commit-message: "chore: update @opentui/* dependencies in templates" | |
| title: "chore: update @opentui/* dependencies in templates" | |
| body: | | |
| This PR updates all `@opentui/*` dependencies in the template packages to their latest versions. | |
| ## Changes | |
| - Updated `@opentui/*` dependencies to latest versions | |
| - Regenerated lockfiles for all templates | |
| ## Generated by | |
| This PR was automatically created by the `update-opentui-deps.yml` GitHub Action. | |
| ## Testing | |
| Please verify that all templates still work correctly after these updates: | |
| ```bash | |
| # Test each template | |
| cd packages/templates/core && bun run src/index.ts | |
| cd packages/templates/react && bun run src/index.tsx | |
| cd packages/templates/solid && bun run src/index.tsx | |
| ``` | |
| branch: update-opentui-dependencies | |
| delete-branch: true | |
| base: main | |
| draft: false | |
| labels: | | |
| dependencies | |
| automated | |
| templates | |
| - name: Summary | |
| if: steps.check-updates.outputs.has-updates == 'true' | |
| run: | | |
| echo "✅ Created pull request to update @opentui/* dependencies" | |
| echo "📋 Please review and merge the PR to apply the updates" | |
| - name: No updates needed | |
| if: steps.check-updates.outputs.has-updates == 'false' | |
| run: | | |
| echo "✅ All @opentui/* dependencies are already up to date" |