standard-version
standard-version copied to clipboard
adding YAML support
Hi,
As we working with some Helm charts, and using conventional commits, we also think that it could be a good idea to use standard-version on them but YAML support does not exist.
As Chart.yaml got a version
key we decided to bring you this PR to support YAML file as general, assuming they have a version
key like JSON updater
Was also looking for a similar feature, but will likely just write an updater for standard-version to invoke.
What about the chart property appVersion
too? version
is just for the chart revision, but appVersion
is for the actual version of the application to be deployed...
Maybe you could specify the property path to update instead of assuming it'll always be version
, and have more control like this:
{
"filename": "a/deep/package/dot/yaml/file/MY_VERSION_TRACKER.yaml",
"type": "yaml",
"propertyPath": "version"
},
{
"filename": "a/deep/package/dot/yaml/file/MY_VERSION_TRACKER.yaml",
"type": "yaml",
"propertyPath": "appVersion"
},
It does make me wonder though, whether this would need to handle when there's a prerelease like "2.0.0-alpha"... does version
allow a string in helm? This is the default created by new helm charts:
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 0.1.0
# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
# follow Semantic Versioning. They should reflect the version the application is using.
# It is recommended to use it with quotes.
appVersion: "1.0.0"
Hi, that could be a good idea
As you printed out, Versions are expected to follow Semantic Versioning
so yes 2.0.0-alpha
as it's semver
But I would LOVE that this PR (and this one ! #591) to be merge before adding propertyPath
as it's could be a generic property and not specific to yaml support
But it seems that this repo is dead ? Lots of issues/questions without any response, PR not followed (the java one is more than one year) I'm so sad as I use it every day
Waiting for this to be merge, you can use my fork as it includes yaml and java support