From ecbba657125aa9ecf7c5901f4a6fa1bf7a6281df Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 8 Jan 2025 15:31:56 +0000 Subject: [PATCH] (deps): Bump JsonSchema.Net.Generation from 4.6.0 to 5.0.0 in /src Bumps [JsonSchema.Net.Generation](https://github.com/json-everything/json-everything) from 4.6.0 to 5.0.0. - [Commits](https://github.com/json-everything/json-everything/compare/schema-gen-v4.6.0...logic-v5.0.0) --- updated-dependencies: - dependency-name: JsonSchema.Net.Generation dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- schemas/6.1/GitVersion.configuration.json | 440 ++++++++++++---------- schemas/6.1/GitVersion.json | 85 ++++- src/Directory.Packages.props | 2 +- src/GitVersion.Schema/Program.cs | 1 - 4 files changed, 314 insertions(+), 214 deletions(-) diff --git a/schemas/6.1/GitVersion.configuration.json b/schemas/6.1/GitVersion.configuration.json index affb98d33e..c23d8a4686 100644 --- a/schemas/6.1/GitVersion.configuration.json +++ b/schemas/6.1/GitVersion.configuration.json @@ -7,7 +7,10 @@ "properties": { "assembly-file-versioning-format": { "description": "Specifies the format of AssemblyFileVersion and overwrites the value of assembly-file-versioning-scheme.", - "type": "string" + "type": [ + "string", + "null" + ] }, "assembly-file-versioning-scheme": { "description": "The scheme to use when setting AssemblyFileVersion attribute. Can be 'MajorMinorPatchTag', 'MajorMinorPatch', 'MajorMinor', 'Major', 'None'. Defaults to 'MajorMinorPatch'.", @@ -17,17 +20,24 @@ "MajorMinorPatch", "MajorMinor", "Major", - "None" + "None", + null ] }, "assembly-informational-format": { "description": "Specifies the format of AssemblyInformationalVersion. Defaults to '{InformationalVersion}'.", "default": "'{InformationalVersion}'", - "type": "string" + "type": [ + "string", + "null" + ] }, "assembly-versioning-format": { "description": "Specifies the format of AssemblyVersion and overwrites the value of assembly-versioning-scheme.", - "type": "string" + "type": [ + "string", + "null" + ] }, "assembly-versioning-scheme": { "description": "The scheme to use when setting AssemblyVersion attribute. Can be 'MajorMinorPatchTag', 'MajorMinorPatch', 'MajorMinor', 'Major', 'None'. Defaults to 'MajorMinorPatch'.", @@ -37,62 +47,209 @@ "MajorMinorPatch", "MajorMinor", "Major", - "None" + "None", + null ] }, "branches": { "description": "The header for all the individual branch configuration.", "type": "object", "additionalProperties": { - "$ref": "#/$defs/branchConfiguration" + "type": "object", + "properties": { + "commit-message-incrementing": { + "description": "Sets whether it should be possible to increment the version with special syntax in the commit message. Can be 'Disabled', 'Enabled' or 'MergeMessageOnly'.", + "enum": [ + "Enabled", + "Disabled", + "MergeMessageOnly", + null + ] + }, + "mode": { + "description": "The deployment mode for this branch. Can be 'ManualDeployment', 'ContinuousDelivery', 'ContinuousDeployment'.", + "enum": [ + "ManualDeployment", + "ContinuousDelivery", + "ContinuousDeployment", + null + ] + }, + "increment": { + "description": "The increment strategy for this branch. Can be 'Inherit', 'Patch', 'Minor', 'Major', 'None'.", + "$ref": "#/$defs/incrementStrategy" + }, + "is-main-branch": { + "description": "When using Mainline mode, this indicates that this branch is a mainline. By default main and support/* are mainlines.", + "type": [ + "boolean", + "null" + ] + }, + "is-release-branch": { + "description": "Indicates this branch configuration represents a release branch in GitFlow.", + "type": [ + "boolean", + "null" + ] + }, + "is-source-branch-for": { + "description": "The branches that this branch is a source branch.", + "$ref": "#/$defs/hashSetOfString" + }, + "label": { + "description": "The label to use for this branch. Use the value {BranchName} or similar as a placeholder to insert a named capture group from RegularExpression (fx. the branch name).", + "type": [ + "string", + "null" + ] + }, + "label-number-pattern": { + "format": "regex", + "description": "The regular expression pattern to use to extract the number from the branch name. Defaults to '[/-](?\\d+)'.", + "default": "[/-](?\\d+)", + "type": [ + "string", + "null" + ] + }, + "pre-release-weight": { + "description": "Provides a way to translate the PreReleaseLabel to a number.", + "type": [ + "integer", + "null" + ] + }, + "prevent-increment": { + "description": "The prevent increment configuration section.", + "$ref": "#/$defs/preventIncrementConfiguration" + }, + "regex": { + "format": "regex", + "description": "The regular expression pattern to use to match this branch.", + "type": [ + "string", + "null" + ] + }, + "source-branches": { + "description": "The source branches for this branch.", + "$ref": "#/$defs/hashSetOfString" + }, + "track-merge-message": { + "description": "This property is a branch related property and gives the user the possibility to control the behavior of whether the merge commit message will be interpreted as a next version or not.", + "type": [ + "boolean", + "null" + ] + }, + "track-merge-target": { + "description": "Strategy which will look for tagged merge commits directly off the current branch.", + "type": [ + "boolean", + "null" + ] + }, + "tracks-release-branches": { + "description": "Indicates this branch configuration represents develop in GitFlow.", + "type": [ + "boolean", + "null" + ] + } + } } }, "commit-date-format": { "description": "The format to use when calculating the commit date. Defaults to 'yyyy-MM-dd'. See [Standard Date and Time Format Strings](https://learn.microsoft.com/en-us/dotnet/standard/base-types/standard-date-and-time-format-strings) and [Custom Date and Time Format Strings](https://learn.microsoft.com/en-us/dotnet/standard/base-types/standard-date-and-time-format-strings).", "default": "yyyy-MM-dd", - "type": "string" + "type": [ + "string", + "null" + ] }, "commit-message-incrementing": { - "$ref": "#/$defs/nullableOfCommitMessageIncrementMode" + "description": "Sets whether it should be possible to increment the version with special syntax in the commit message. Can be 'Disabled', 'Enabled' or 'MergeMessageOnly'.", + "enum": [ + "Enabled", + "Disabled", + "MergeMessageOnly", + null + ] }, "mode": { - "$ref": "#/$defs/nullableOfDeploymentMode" + "description": "The deployment mode for this branch. Can be 'ManualDeployment', 'ContinuousDelivery', 'ContinuousDeployment'.", + "enum": [ + "ManualDeployment", + "ContinuousDelivery", + "ContinuousDeployment", + null + ] }, "ignore": { "description": "The header property for the ignore configuration.", "type": "object", "properties": { "commits-before": { - "$ref": "#/$defs/string3" + "format": "date-time", + "description": "Commits before this date will be ignored. Format: yyyy-MM-ddTHH:mm:ss.", + "type": [ + "string", + "null" + ] }, "sha": { - "$ref": "#/$defs/hashSetOfString2" + "description": "A sequence of SHAs to be excluded from the version calculations.", + "$ref": "#/$defs/hashSetOfString" } } }, "increment": { + "description": "The increment strategy for this branch. Can be 'Inherit', 'Patch', 'Minor', 'Major', 'None'.", "$ref": "#/$defs/incrementStrategy" }, "is-main-branch": { - "$ref": "#/$defs/nullableOfBoolean" + "description": "When using Mainline mode, this indicates that this branch is a mainline. By default main and support/* are mainlines.", + "type": [ + "boolean", + "null" + ] }, "is-release-branch": { - "$ref": "#/$defs/nullableOfBoolean1" + "description": "Indicates this branch configuration represents a release branch in GitFlow.", + "type": [ + "boolean", + "null" + ] }, "is-source-branch-for": { + "description": "The branches that this branch is a source branch.", "$ref": "#/$defs/hashSetOfString" }, "label": { - "$ref": "#/$defs/string" + "description": "The label to use for this branch. Use the value {BranchName} or similar as a placeholder to insert a named capture group from RegularExpression (fx. the branch name).", + "type": [ + "string", + "null" + ] }, "label-number-pattern": { - "$ref": "#/$defs/string1" + "format": "regex", + "description": "The regular expression pattern to use to extract the number from the branch name. Defaults to '[/-](?\\d+)'.", + "default": "[/-](?\\d+)", + "type": [ + "string", + "null" + ] }, "major-version-bump-message": { "format": "regex", "description": "The regular expression to match commit messages with to perform a major version increment. Defaults to '\\+semver:\\s?(breaking|major)'", "default": "\\+semver:\\s?(breaking|major)", - "type": "string" + "type": [ + "string", + "null" + ] }, "merge-message-formats": { "description": "Custom merge message formats to enable identification of merge messages that do not follow the built-in conventions.", @@ -105,32 +262,54 @@ "format": "regex", "description": "The regular expression to match commit messages with to perform a minor version increment. Defaults to '\\+semver:\\s?(feature|minor)'", "default": "\\+semver:\\s?(feature|minor)", - "type": "string" + "type": [ + "string", + "null" + ] }, "next-version": { "description": "Allows you to bump the next version explicitly. Useful for bumping main or a feature branch with breaking changes", - "type": "string" + "type": [ + "string", + "null" + ] }, "no-bump-message": { "format": "regex", "description": "Used to tell GitVersion not to increment when in Mainline development mode. Defaults to '\\+semver:\\s?(none|skip)'", "default": "\\+semver:\\s?(none|skip)", - "type": "string" + "type": [ + "string", + "null" + ] }, "patch-version-bump-message": { "format": "regex", "description": "The regular expression to match commit messages with to perform a patch version increment. Defaults to '\\+semver:\\s?(fix|patch)'", "default": "\\+semver:\\s?(fix|patch)", - "type": "string" + "type": [ + "string", + "null" + ] }, "pre-release-weight": { - "$ref": "#/$defs/nullableOfInt32" + "description": "Provides a way to translate the PreReleaseLabel to a number.", + "type": [ + "integer", + "null" + ] }, "prevent-increment": { + "description": "The prevent increment configuration section.", "$ref": "#/$defs/preventIncrementConfiguration" }, "regex": { - "$ref": "#/$defs/string2" + "format": "regex", + "description": "The regular expression pattern to use to match this branch.", + "type": [ + "string", + "null" + ] }, "semantic-version-format": { "description": "Specifies the semantic version format that is used when parsing the string. Can be 'Strict' or 'Loose'. Defaults to 'Strict'.", @@ -141,13 +320,17 @@ ] }, "source-branches": { - "$ref": "#/$defs/hashSetOfString1" + "description": "The source branches for this branch.", + "$ref": "#/$defs/hashSetOfString" }, "tag-prefix": { "format": "regex", "description": "A regular expression which is used to trim Git tags before processing. Defaults to '[vV]?'", "default": "[vV]?", - "type": "string" + "type": [ + "string", + "null" + ] }, "tag-pre-release-weight": { "description": "The pre-release weight in case of tagged commits. Defaults to 60000.", @@ -157,13 +340,25 @@ ] }, "track-merge-message": { - "$ref": "#/$defs/nullableOfBoolean4" + "description": "This property is a branch related property and gives the user the possibility to control the behavior of whether the merge commit message will be interpreted as a next version or not.", + "type": [ + "boolean", + "null" + ] }, "track-merge-target": { - "$ref": "#/$defs/nullableOfBoolean5" + "description": "Strategy which will look for tagged merge commits directly off the current branch.", + "type": [ + "boolean", + "null" + ] }, "tracks-release-branches": { - "$ref": "#/$defs/nullableOfBoolean6" + "description": "Indicates this branch configuration represents develop in GitFlow.", + "type": [ + "boolean", + "null" + ] }, "update-build-number": { "description": "Whether to update the build number in the project file. Defaults to true.", @@ -174,13 +369,15 @@ "format": "regex", "description": "A regular expression which is used to determine the version number in the branch name or commit message (e.g., v1.0.0-LTS). Defaults to '(?[vV]?\\d+(\\.\\d+)?(\\.\\d+)?).*'.", "default": "(?[vV]?\\d+(\\.\\d+)?(\\.\\d+)?).*", - "type": "string" + "type": [ + "string", + "null" + ] }, "strategies": { "description": "Specifies which version strategies (one or more) will be used to determine the next version. Following values are available: 'ConfiguredNextVersion', 'MergeMessage', 'TaggedCommit', 'TrackReleaseBranches', 'VersionInBranchName' and 'Mainline'.", "type": "array", "items": { - "description": "Specifies which version strategies (one or more) will be used to determine the next version. Following values are available: 'ConfiguredNextVersion', 'MergeMessage', 'TaggedCommit', 'TrackReleaseBranches', 'VersionInBranchName' and 'Mainline'.", "enum": [ "None", "Fallback", @@ -195,78 +392,14 @@ }, "workflow": { "description": "The base template of the configuration to use. Possible values are: 'GitFlow/v1' or 'GitHubFlow/v1'", - "type": "string" + "type": [ + "string", + "null" + ] } }, "$defs": { - "branchConfiguration": { - "type": "object", - "properties": { - "commit-message-incrementing": { - "$ref": "#/$defs/nullableOfCommitMessageIncrementMode" - }, - "mode": { - "$ref": "#/$defs/nullableOfDeploymentMode" - }, - "increment": { - "$ref": "#/$defs/incrementStrategy" - }, - "is-main-branch": { - "$ref": "#/$defs/nullableOfBoolean" - }, - "is-release-branch": { - "$ref": "#/$defs/nullableOfBoolean1" - }, - "is-source-branch-for": { - "$ref": "#/$defs/hashSetOfString" - }, - "label": { - "$ref": "#/$defs/string" - }, - "label-number-pattern": { - "$ref": "#/$defs/string1" - }, - "pre-release-weight": { - "$ref": "#/$defs/nullableOfInt32" - }, - "prevent-increment": { - "$ref": "#/$defs/preventIncrementConfiguration" - }, - "regex": { - "$ref": "#/$defs/string2" - }, - "source-branches": { - "$ref": "#/$defs/hashSetOfString1" - }, - "track-merge-message": { - "$ref": "#/$defs/nullableOfBoolean4" - }, - "track-merge-target": { - "$ref": "#/$defs/nullableOfBoolean5" - }, - "tracks-release-branches": { - "$ref": "#/$defs/nullableOfBoolean6" - } - } - }, - "nullableOfCommitMessageIncrementMode": { - "description": "Sets whether it should be possible to increment the version with special syntax in the commit message. Can be 'Disabled', 'Enabled' or 'MergeMessageOnly'.", - "enum": [ - "Enabled", - "Disabled", - "MergeMessageOnly" - ] - }, - "nullableOfDeploymentMode": { - "description": "The deployment mode for this branch. Can be 'ManualDeployment', 'ContinuousDelivery', 'ContinuousDeployment'.", - "enum": [ - "ManualDeployment", - "ContinuousDelivery", - "ContinuousDeployment" - ] - }, "incrementStrategy": { - "description": "The increment strategy for this branch. Can be 'Inherit', 'Patch', 'Minor', 'Major', 'None'.", "enum": [ "None", "Major", @@ -275,120 +408,37 @@ "Inherit" ] }, - "nullableOfBoolean": { - "description": "When using Mainline mode, this indicates that this branch is a mainline. By default main and support/* are mainlines.", - "type": [ - "boolean", - "null" - ] - }, - "nullableOfBoolean1": { - "description": "Indicates this branch configuration represents a release branch in GitFlow.", - "type": [ - "boolean", - "null" - ] - }, "hashSetOfString": { - "description": "The branches that this branch is a source branch.", "type": "array", "items": { - "description": "The branches that this branch is a source branch.", "type": "string" } }, - "string": { - "description": "The label to use for this branch. Use the value {BranchName} or similar as a placeholder to insert a named capture group from RegularExpression (fx. the branch name).", - "type": "string" - }, - "string1": { - "format": "regex", - "description": "The regular expression pattern to use to extract the number from the branch name. Defaults to '[/-](?\\d+)'.", - "default": "[/-](?\\d+)", - "type": "string" - }, - "nullableOfInt32": { - "description": "Provides a way to translate the PreReleaseLabel to a number.", - "type": [ - "integer", - "null" - ] - }, "preventIncrementConfiguration": { - "description": "The prevent increment configuration section.", "type": "object", "properties": { "of-merged-branch": { - "$ref": "#/$defs/nullableOfBoolean2" + "description": "Prevent increment when branch merged.", + "type": [ + "boolean", + "null" + ] }, "when-branch-merged": { - "$ref": "#/$defs/nullableOfBoolean2" + "description": "Prevent increment when branch merged.", + "type": [ + "boolean", + "null" + ] }, "when-current-commit-tagged": { - "$ref": "#/$defs/nullableOfBoolean3" + "description": "This branch related property controls the behavior whether to use the tagged (value set to true) or the incremented (value set to false) semantic version. Defaults to true.", + "type": [ + "boolean", + "null" + ] } } - }, - "nullableOfBoolean2": { - "description": "Prevent increment when branch merged.", - "type": [ - "boolean", - "null" - ] - }, - "nullableOfBoolean3": { - "description": "This branch related property controls the behavior whether to use the tagged (value set to true) or the incremented (value set to false) semantic version. Defaults to true.", - "type": [ - "boolean", - "null" - ] - }, - "string2": { - "format": "regex", - "description": "The regular expression pattern to use to match this branch.", - "type": "string" - }, - "hashSetOfString1": { - "description": "The source branches for this branch.", - "type": "array", - "items": { - "description": "The source branches for this branch.", - "type": "string" - } - }, - "nullableOfBoolean4": { - "description": "This property is a branch related property and gives the user the possibility to control the behavior of whether the merge commit message will be interpreted as a next version or not.", - "type": [ - "boolean", - "null" - ] - }, - "nullableOfBoolean5": { - "description": "Strategy which will look for tagged merge commits directly off the current branch.", - "type": [ - "boolean", - "null" - ] - }, - "nullableOfBoolean6": { - "description": "Indicates this branch configuration represents develop in GitFlow.", - "type": [ - "boolean", - "null" - ] - }, - "string3": { - "format": "date-time", - "description": "Commits before this date will be ignored. Format: yyyy-MM-ddTHH:mm:ss.", - "type": "string" - }, - "hashSetOfString2": { - "description": "A sequence of SHAs to be excluded from the version calculations.", - "type": "array", - "items": { - "description": "A sequence of SHAs to be excluded from the version calculations.", - "type": "string" - } } } } \ No newline at end of file diff --git a/schemas/6.1/GitVersion.json b/schemas/6.1/GitVersion.json index 037e6acbf4..9c4e5945ab 100644 --- a/schemas/6.1/GitVersion.json +++ b/schemas/6.1/GitVersion.json @@ -7,15 +7,24 @@ "properties": { "AssemblySemFileVer": { "description": "Suitable for .NET AssemblyFileVersion. Defaults to Major.Minor.Patch.0.", - "type": "string" + "type": [ + "string", + "null" + ] }, "AssemblySemVer": { "description": "Suitable for .NET AssemblyVersion. Defaults to Major.Minor.0.0", - "type": "string" + "type": [ + "string", + "null" + ] }, "BranchName": { "description": "The name of the checked out Git branch.", - "type": "string" + "type": [ + "string", + "null" + ] }, "BuildMetaData": { "description": "The build metadata, usually representing number of commits since the VersionSourceSha.", @@ -26,7 +35,10 @@ }, "CommitDate": { "description": "The ISO-8601 formatted date of the commit identified by Sha.", - "type": "string" + "type": [ + "string", + "null" + ] }, "CommitsSinceVersionSource": { "description": "The number of commits since the version source.", @@ -37,19 +49,31 @@ }, "EscapedBranchName": { "description": "Equal to BranchName, but with / replaced with -.", - "type": "string" + "type": [ + "string", + "null" + ] }, "FullBuildMetaData": { "description": "The BuildMetaData suffixed with BranchName and Sha.", - "type": "string" + "type": [ + "string", + "null" + ] }, "FullSemVer": { "description": "The full, SemVer 2.0 compliant version number.", - "type": "string" + "type": [ + "string", + "null" + ] }, "InformationalVersion": { "description": "Suitable for .NET AssemblyInformationalVersion. Defaults to FullSemVer suffixed by FullBuildMetaData.", - "type": "string" + "type": [ + "string", + "null" + ] }, "Major": { "description": "The major version. Should be incremented on breaking changes.", @@ -60,7 +84,10 @@ }, "MajorMinorPatch": { "description": "Major, Minor and Patch joined together, separated by '.'.", - "type": "string" + "type": [ + "string", + "null" + ] }, "Minor": { "description": "The minor version. Should be incremented on new features.", @@ -78,11 +105,17 @@ }, "PreReleaseLabel": { "description": "The pre-release label is the name of the pre-release.", - "type": "string" + "type": [ + "string", + "null" + ] }, "PreReleaseLabelWithDash": { "description": "The pre-release label prefixed with a dash.", - "type": "string" + "type": [ + "string", + "null" + ] }, "PreReleaseNumber": { "description": "The pre-release number is the number of commits since the last version bump.", @@ -93,23 +126,38 @@ }, "PreReleaseTag": { "description": "The pre-release tag is the pre-release label suffixed by the PreReleaseNumber.", - "type": "string" + "type": [ + "string", + "null" + ] }, "PreReleaseTagWithDash": { "description": "The pre-release tag prefixed with a dash.", - "type": "string" + "type": [ + "string", + "null" + ] }, "SemVer": { "description": "The semantic version number, including PreReleaseTagWithDash for pre-release version numbers.", - "type": "string" + "type": [ + "string", + "null" + ] }, "Sha": { "description": "The SHA of the Git commit.", - "type": "string" + "type": [ + "string", + "null" + ] }, "ShortSha": { "description": "The Sha limited to 7 characters.", - "type": "string" + "type": [ + "string", + "null" + ] }, "UncommittedChanges": { "description": "The number of uncommitted changes present in the repository.", @@ -120,7 +168,10 @@ }, "VersionSourceSha": { "description": "The SHA of the commit used as version source.", - "type": "string" + "type": [ + "string", + "null" + ] }, "WeightedPreReleaseNumber": { "description": "A summation of branch specific pre-release-weight and the PreReleaseNumber. Can be used to obtain a monotonically increasing version number across the branches.", diff --git a/src/Directory.Packages.props b/src/Directory.Packages.props index e88abe658f..18afaff8c2 100644 --- a/src/Directory.Packages.props +++ b/src/Directory.Packages.props @@ -19,7 +19,7 @@ - + diff --git a/src/GitVersion.Schema/Program.cs b/src/GitVersion.Schema/Program.cs index ba84aed254..60451c13b2 100644 --- a/src/GitVersion.Schema/Program.cs +++ b/src/GitVersion.Schema/Program.cs @@ -12,7 +12,6 @@ var configuration = new SchemaGeneratorConfiguration { PropertyNameResolver = PropertyNameResolvers.KebabCase, - Nullability = Nullability.AllowForNullableValueTypes, PropertyOrder = PropertyOrder.ByName, };