Skip to content
This repository was archived by the owner on May 27, 2025. It is now read-only.

Conversation

@ShookLyngs
Copy link
Collaborator

@ShookLyngs ShookLyngs commented May 23, 2024

Changes

  • Fix #163 by ensuring a temp changeset is always added before the changeset version command is executed
  • Fix snapshot versioning by reverting code, should not run version command in the changesets/action

Related issues

Proof

When releasing snapshots, we expect each package to be versioned as 0.0.0-snap-{timestamp}, and things should work as expected if the .changeset folder contains at least one changeset. If the condition has not been met, the changeset version command will be skipped, which causes the versions of the packages and the changelog file remain the same as before.

An example of skipping (which causes the #163 issue):

% changeset version --snapshot snap
🦋  warn No unreleased changesets found, exiting.

To address the issue, an extra step has been added to the snapshot.yml workflow to always add a temp changest before executing the changeset version command. This extra step ensures the versioning command will always updates the versions of the packages, instead of doing nothing.

Here's an example action where the repo contains no changeset in the .changeset folder, even though the versioning command worked and the snapshot was released successfully. Therefore I believe the issue is considered resolved: https://github.com/ShookLyngs/test-changesets/actions/runs/9214982527/job/25352404438#step:9:9

Run npx changeset version --snapshot snap
🦋  All files have been updated. Review them and commit at your leisure

@ShookLyngs ShookLyngs requested a review from Flouse May 23, 2024 21:57
@ShookLyngs ShookLyngs self-assigned this May 23, 2024
@Flouse Flouse merged commit f247319 into develop May 24, 2024
@Flouse Flouse deleted the chore/fix-snapshot branch May 24, 2024 03:23
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Changesets force-published local version without consent

3 participants