chore(deps): Bump ghcr.io/devcontainers/features/docker-in-docker (#24) #22
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: Create version PR | |
| on: | |
| push: | |
| branches: | |
| - main | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| jobs: | |
| version-pr: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 # Need full history for git operations | |
| - name: Configure Git | |
| run: | | |
| git config user.name "github-actions[bot]" | |
| git config user.email "github-actions[bot]@users.noreply.github.com" | |
| - name: Setup Go | |
| uses: actions/setup-go@v6 | |
| with: | |
| go-version-file: go.mod | |
| - name: Install tools | |
| run: go install tool | |
| - name: Create or update release PR | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| run: | | |
| changeset each --filter open-changesets -- sh -c ' | |
| set -e | |
| BRANCH="changeset-release/$PROJECT" | |
| echo "📦 Creating PR for $PROJECT..." | |
| git checkout -b "$BRANCH" 2>/dev/null || git checkout "$BRANCH" | |
| # Run version - this deletes changesets | |
| changeset version \ | |
| --owner ${{ github.repository_owner }} \ | |
| --repo ${{ github.event.repository.name }} | |
| if git diff --quiet && git diff --cached --quiet; then | |
| echo "⚠️ No changes to commit for $PROJECT" | |
| git checkout main | |
| exit 0 | |
| fi | |
| VERSION=$(cat "$PROJECT_PATH/version.txt" 2>/dev/null || echo "unknown") | |
| git add . | |
| git commit -m "chore: version $PROJECT to $VERSION" | |
| git push -u origin "$BRANCH" --force | |
| changeset gh pr open \ | |
| --owner ${{ github.repository_owner }} \ | |
| --repo ${{ github.event.repository.name }} | |
| git checkout main | |
| git reset --hard origin/main | |
| git clean -fd | |
| echo "✅ PR created/updated for $PROJECT" | |
| ' |