Skip to content

Conversation

@pasevin
Copy link
Collaborator

@pasevin pasevin commented Aug 12, 2025

Fixes the update-versions workflow that was failing due to detached HEAD state when trying to push changes.\n\n## Problem\nThe workflow was failing with:\n\nfatal: You are not currently on a branch.\nTo push the history leading to the current (detached HEAD)\nstate now, use\n git push origin HEAD:<name-of-remote-branch>\n\n\n## Solution\nAdded branch checkout logic that handles both PR and push events:\n\nyaml\nBRANCH_NAME="${{ github.head_ref || github.ref_name }}"\ngit checkout "$BRANCH_NAME"\n\n\nThis ensures the workflow operates on the proper branch instead of a detached HEAD state.

@pasevin pasevin requested review from a team as code owners August 12, 2025 14:00
env:
HUSKY: 0 # Disable husky hooks for automated commits
run: |
git config --local user.email "github-actions[bot]@users.noreply.github.com"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible to use the GH release app?

@pasevin pasevin merged commit 10335d1 into main Aug 12, 2025
11 checks passed
pasevin added a commit that referenced this pull request Aug 12, 2025
pasevin added a commit that referenced this pull request Aug 12, 2025
* Version Packages

* fix(ci): disable husky hooks in update-versions workflow (#97)

* chore(common): update export versions

* Version Packages

* fix(ci): remove extra quote in export-testing workflow token parameter (#98)

* Version Packages

* fix(ci): checkout proper branch before committing in update-versions workflow (#100)

* feat(builder): replace contracts wizard icon with custom SVG (#99)

* Version Packages

* chore: update export versions

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Aleksandr Pasevin <pasevin@gmail.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
pasevin added a commit that referenced this pull request Aug 14, 2025
* Version Packages

* fix(ci): disable husky hooks in update-versions workflow (#97)

* chore(common): update export versions

* Version Packages

* fix(ci): remove extra quote in export-testing workflow token parameter (#98)

* Version Packages

* fix(ci): checkout proper branch before committing in update-versions workflow (#100)

* feat(builder): replace contracts wizard icon with custom SVG (#99)

* Version Packages

* chore: update export versions

* Version Packages

* chore: update export versions

* fix(builder): correct snapshot update command in export version script

- Fix updateSnapshots() to target specific export tests instead of all tests
- Ensures changesets bumps update both versions.ts and test snapshots correctly
- Prevents snapshot test failures in changesets PRs like #116

* fix(ci): update workflow to commit both versions.ts and snapshot files

- Fix update-versions.yml to check for changes in both files
- Commit both versions.ts and snapshot files when updating versions
- Ensures complete automation of version bumps with correct snapshots

* fix(builder): always update snapshots regardless of versions.ts changes

- Fix critical logic bug where snapshots weren't updated when versions.ts was already current
- Ensures snapshots always match current package versions
- Resolves snapshot test failures in changesets PRs like #116
- Snapshots are now updated unconditionally to prevent stale snapshot issues

* fix(ci): add build step before snapshot updates in update-versions workflow

- Fix CI build dependency issue where snapshot tests fail due to unbuilt packages
- Add 'pnpm run build' step before running update-export-versions
- Ensures adapter packages are built and available for import during snapshot tests
- Resolves 'Failed to resolve entry for package' errors in CI environment

* chore: update export versions and test snapshots

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Aleksandr Pasevin <pasevin@gmail.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: oz-release-app[bot] <205211949+oz-release-app[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants