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

Fix version URLs in gitlab repos #12

Merged
merged 2 commits into from
Jun 6, 2021
Merged

Conversation

tamaracha
Copy link
Contributor

In Gitlab, the compare tool doesn't accept HEAD in the revision range, only tags and branches are allowed. This PR adds the possibility to configure the name of the head revision in an additional plugin option, so the plugin can also generate version URLs for gitlab repos.

  • Add head option, defaults to 'HEAD'
  • Use the value of head option where HEAD was hardcoded before
  • Add a test with custom head set to 'main'

…re range

- Add head option, defaults to 'HEAD'
- Use the value of head option where HEAD was hardcoded
- Add a test with custom head
@@ -28,3 +28,4 @@ In [release-it](https://github.com/release-it/release-it) config:
| addUnreleased | `false` | It leaves "Unreleased" title row if set to `true`. |
| keepUnreleased | `false` | It leaves "Unreleased" title row unchanged if set to `true`. |
| addVersionUrl | `false` | Links the version to the according changeset. |
| head | `'HEAD'` | The git revision the new version tag is compared to in the Unreleased URL. |
Copy link
Collaborator

@eMarek eMarek Jan 9, 2021

Choose a reason for hiding this comment

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

If you don't mind, could you please wrap CHANGELOG.md on line 26 into single quotes as 'CHANGELOG.md'. The same way as you made for 'HEAD' . Thanks!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sure, already done ;-)

@eMarek
Copy link
Collaborator

eMarek commented Jan 9, 2021

@webpro please merge and make a new release if it looks okay to you.

@webpro webpro merged commit 9290fb4 into release-it:master Jun 6, 2021
@webpro
Copy link
Contributor

webpro commented Jun 6, 2021

Sorry for the late reply! Thanks @tamaracha and @eMarek for this. Just released as v2.3.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

Successfully merging this pull request may close these issues.

3 participants