You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Breaking: Push commit and tag by default with opt-out flag (#47)
Previously only -R (release) pushed, leaving the push implicit
and surprising in that one flow (#44). Both GitHub and Gitea
require the commit to exist on the remote before a release can
be created, so the push cannot be eliminated for -R. Make push
the default after commit+tag, with -n/--no-push to opt out
(incompatible with --release). Add -o/--remote (default
"origin") and -B/--branch (default current branch) to override
the push target. Release forge detection follows --remote so
the release lands where the push went. Detached HEAD and flag
validation now happen before any git mutation.
Closes#44
Co-authored-by: Claude (Opus 4.6) <noreply@anthropic.com>
-g, --gitless Do not perform any git action like creating commit and tag
28
28
-D, --dry Do not create a tag or commit, just print what would be done
29
29
-R, --release Create a GitHub or Gitea release with the changelog as body
30
+
-n, --no-push Skip pushing commit and tag
31
+
-o, --remote <name> Git remote to push to. Default is "origin"
32
+
-B, --branch <name> Git branch to push. Default is the current branch
30
33
-V, --verbose Print verbose output to stderr
31
34
-v, --version Print the version
32
35
-h, --help Print this help
@@ -54,9 +57,13 @@ To automatically sign commits and tags created by `versions` with GPG add this t
54
57
gpgSign = if-asked
55
58
```
56
59
60
+
## Pushing
61
+
62
+
By default, `versions` pushes the commit and tag to `origin` after creating them. Pass `--no-push` to skip the push and keep changes local. Use `--remote` and `--branch` to override the target remote and branch.
63
+
57
64
## Creating releases
58
65
59
-
When using the `--release` option, `versions` will automatically create a GitHub or Gitea release after creating the tag. The release body will contain the same changelog as the commit message.
66
+
When using the `--release` option, `versions` will automatically create a GitHub or Gitea release after pushing the tag. The release body will contain the same changelog as the commit message. `--release` requires the push and is incompatible with `--no-push`.
60
67
61
68
The tool will automatically detect whether you're using GitHub or Gitea based on your git remote URL.
0 commit comments