chore(deps): update dependency knope to v0.12.0 #862
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
0.11.0
->0.12.0
Release Notes
knope-dev/knope (knope)
v0.12.0
Compare Source
Breaking Changes
Prevent bumping major version of a
go.mod
fileAccording to the docs, aside from the
v0
->v1
transition,go.mod
files should not be updated for new major versions, but instead a newv{major}
directory should be created with a newgo.mod
file. This is for compatibility with older versions of Go tools.In order to prevent someone from accidentally doing the wrong thing, Knope will no longer bump a
go.mod
file tov2
unless--override-version
is used to bypass this check. Additionally, if ago.mod
file is in the matching versioned directory (e.g., thego.mod
file ending in/v2
is under a directory calledv2
), Knope will not allow the major version of that file to be bumped, as it would break the package.Fixes
Handle version-specific go modules correctly
Fixes #584 from @BatmanAoD.
If you have a
go.mod
file representing a specific major version in a directory (as recommended in the go docs), Knope will now tag it correctly. Previously, av2/go.mod
file would generate a tag likev2/v2.1.3
. Now, it will generate a tag likev2.1.3
.Additionally, when determining the current version for a
go.mod
file, only tags which match the major version of thego.mod
file will be considered.Properly version named packages containing a root
go.mod
fileConsider this package config in a
knope.toml
:The
Release
step previously (and will still) add a tag likesomething/v1.2.3
, however the correct Go module tag isv1.2.3
(without the package name prefix). Knope will now correctly add this second tag (previously, top-level tags were only added for single-package repos).Documentation
Document conflict between package names and go module names
It is possible to write a
knope.toml
file which will cause conflicting tags during theRelease
step if you havego.mod
files in nested directories. This is now documented.v0.11.1
Compare Source
Features
Add a
ChangelogEntry
variable for substitutionAnywhere that the existing
Version
variable can be used (for example, in [theCommand
step][the Command step]), you can now also useChangelogEntry
to get the section of the changelog that corresponds to the current version. For example, you could (almost) replicate Knope's GitHub Release creation without Knope's GitHub integration with a workflow like this:Added an
allow_empty
option to thePrepareRelease
stepCloses #416
If you want to run
PrepareRelease
on every push to a branch without it failing when there's nothing to release, you can now include theallow_empty
option like this:Then, you can use some logic to gracefully skip the rest of your CI process if there is nothing to release. For example, in GitHub Actions, you could do something like this:
This allows you to differentiate between there being nothing to release and the
PrepareRelease
step failing for other reasons.New
CreatePullRequest
stepThe new [
CreatePullRequest
step][CreatePullRequest step] allows you to create or update a pull request on GitHub. It's designed to be a nice way to preview and accept new releases via a pull request workflow, but could certainly work for more contexts as well! To see an example of the new PR-based release workflow, check out Knope's prepare-release workflow and Knope's release workflow.Fixes
Only consider prereleases newer than the last stable
This fixes a regression in the previous version of Knope where all prereleases would be considered, rather than just those tagged after the latest stable version.
Documentation
GitHub Actions Recipes
There's a new section of the docs with some recipes for using Knope in GitHub Actions. If you have suggestions for additional recipes, please open a discussion!
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate. View repository job log here.