Skip to content

fix commit triggers a minor release instead of a patch one #99

@ornanovitch

Description

@ornanovitch

Hi there and thanks a lot for Release-it and this plugin!

With this conf:

[git]
requireCommits = true
commit = false
getLatestTagFromAllRefs = true
[plugins]
[plugins."@release-it/conventional-changelog"]
infile = "CHANGELOG.md"
  [plugins."@release-it/conventional-changelog".preset]
  name = "conventionalcommits"
[plugins."@release-it/bumper"]
  in = ["package.json", "pyproject.toml"]
  out = ["package.json", "pyproject.toml"]

I got the following bump proposal from Release-it after a simple fix commit, I think this is not normal, I should get a patch release:

~ npx release-it --no-npm --dry-run
$ git diff --quiet HEAD
$ git rev-parse --abbrev-ref HEAD
dev
$ git config --get branch.dev.remote
origin
$ git remote get-url origin
git@{masked}
! git fetch
$ git rev-parse --abbrev-ref HEAD  [cached]
$ git -c "versionsort.suffix=-" for-each-ref --count=1 --sort=-v:refname --format="%(refname:short)" refs/tags/*
0.1.1
$ git symbolic-ref HEAD
refs/heads/dev
$ git for-each-ref --format="%(upstream:short)" refs/heads/dev
origin/dev
$ git -c "versionsort.suffix=-" for-each-ref --count=1 --sort=-v:refname --format="%(refname:short)" refs/tags/*  [cached]
$ git rev-list 0.1.1..HEAD --count
3

🚀 Let's release {masked} (0.1.1...0.2.0)


Changelog:
## [0.2.0]({masked}/compare/0.1.1...0.2.0) (2024-10-03)

### Bug Fixes
* adjust release-it ([090f7a0]({masked}/commit/090f7a07f1e5984a0b40a37c93f4ddeaf6362fc2))

$ Writing version to package.json
$ Writing version to pyproject.toml
$ Writing changelog to CHANGELOG.md
? Tag (0.2.0)? Yes
! git tag --annotate --message Release 0.2.0 0.2.0
? Push? Yes
$ git symbolic-ref HEAD  [cached]
$ git for-each-ref --format="%(upstream:short)" refs/heads/dev  [cached]
! git push --follow-tags
🏁 Done (in 3s.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions