Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unclear how should the initial release look like #19

Open
mitar opened this issue Dec 16, 2021 · 3 comments
Open

Unclear how should the initial release look like #19

mitar opened this issue Dec 16, 2021 · 3 comments

Comments

@mitar
Copy link

mitar commented Dec 16, 2021

I am trying to make the first release and I am getting the following error:

Missing section for previous release ("0.0.0") in CHANGELOG.md.

I prepared the following changelog:

# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

### Added

- First public release.

[Unreleased]: https://gitlab.com/example/project/-/compare/firstcommit...main
@johanhammar
Copy link
Contributor

Hi

Try release-it --no-plugins.@release-it/keep-a-changelog.strictLatest

Source https://github.com/release-it/release-it/blob/master/docs/configuration.md

@mitar
Copy link
Author

mitar commented Dec 16, 2021

Setting strictLatest: false did indeed help me make a release, but it did not update changelog at all. What should be the git.changelog setting when using this plugin? I set it to "".

@mitar
Copy link
Author

mitar commented Dec 16, 2021

Oh, I had keepUnreleased also set and it made not change the changelog at all. A very confusion setting. Not sure why it exists. :-)

Changing it to addUnreleased made it change the changelog, almost perfect:

# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

## [0.1.0] - 2021-12-16

### Added

- First public release.

[Unreleased]: https://gitlab.com/example/project/compare/v0.1.0...main

[0.1.0]: https://gitlab.com/example/project/compare/null...v0.1.0

It added an extra empty line between two references at the end and made invalid the last reference.

I would expect it to change it to:

[Unreleased]: https://gitlab.com/example/project/-/compare/v0.1.0...main
[0.1.0]: https://gitlab.com/example/project/-/tags/v0.1.0

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

No branches or pull requests

2 participants