Skip to content

Commit

Permalink
Merge pull request #26 from camptocamp/no-additional-properties
Browse files Browse the repository at this point in the history
Disallow additional properties
  • Loading branch information
sbrunner authored Nov 28, 2024
2 parents f999b3c + dcb1463 commit 7f84316
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 13 deletions.
26 changes: 13 additions & 13 deletions config.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ _Tag Publish configuration file (.github/publish.yaml)_

## Properties

- **`transformers`** _(object)_: The version transform configurations. Default: `{"pull_request_to_version_re": [{"to": "pr-\\1"}]}`.
- **`transformers`** _(object)_: The version transform configurations. Cannot contain additional properties. Default: `{"pull_request_to_version_re": [{"to": "pr-\\1"}]}`.
- **`branch_to_version`**: Refer to _[#/definitions/transform](#definitions/transform)_.
- **`tag_to_version`**: Refer to _[#/definitions/transform](#definitions/transform)_.
- **`pull_request_to_version`**: Refer to _[#/definitions/transform](#definitions/transform)_.
Expand All @@ -13,55 +13,55 @@ _Tag Publish configuration file (.github/publish.yaml)_
- **`node`**: Refer to _[#/definitions/node](#definitions/node)_.
- **`helm`**: Refer to _[#/definitions/helm](#definitions/helm)_.
- **`dispatch`** _(array)_: Default: `[]`.
- **Items** _(object)_: Send a dispatch event to an other repository. Default: `{}`.
- **Items** _(object)_: Send a dispatch event to an other repository. Cannot contain additional properties. Default: `{}`.
- **`repository`** _(string)_: The repository name to be triggered. Default: `"camptocamp/argocd-gs-gmf-apps"`.
- **`event_type`** _(string)_: The event type to be triggered. Default: `"published"`.

## Definitions

- <a id="definitions/docker"></a>**`docker`** _(object)_: The configuration used to publish on Docker.
- <a id="definitions/docker"></a>**`docker`** _(object)_: The configuration used to publish on Docker. Cannot contain additional properties.
- **`latest`** _(boolean)_: Publish the latest version on tag latest. Default: `true`.
- **`images`** _(array)_: List of images to be published.
- **Items** _(object)_
- **Items** _(object)_: Cannot contain additional properties.
- **`group`** _(string)_: The image is in the group, should be used with the --group option of tag-publish script. Default: `"default"`.
- **`name`** _(string)_: The image name.
- **`tags`** _(array)_: The tag name, will be formatted with the version=<the version>, the image with version=latest should be present when we call the tag-publish script. Default: `["{version}"]`.
- **Items** _(string)_
- **`repository`** _(object)_: The repository where we should publish the images. Can contain additional properties. Default: `{"github": {"host": "ghcr.io", "versions_type": ["tag", "default_branch", "stabilization_branch", "rebuild"]}}`.
- **Additional properties** _(object)_
- **Additional properties** _(object)_: Cannot contain additional properties.
- **`host`** _(string)_: The host of the repository URL.
- **`versions_type`** _(array)_: The kind or version that should be published, tag, branch or value of the --version argument of the tag-publish script. Default: `["tag", "default_branch", "stabilization_branch", "rebuild", "feature_branch", "pull_request"]`.
- **Items** _(string)_
- **`github_oidc_login`** _(boolean)_: Auto login to the GitHub Docker registry. Default: `true`.
- <a id="definitions/pypi"></a>**`pypi`** _(object)_: Configuration to publish on pypi.
- <a id="definitions/pypi"></a>**`pypi`** _(object)_: Configuration to publish on pypi. Cannot contain additional properties.
- **`packages`** _(array)_: The configuration of packages that will be published.
- **Items** _(object)_: The configuration of package that will be published.
- **Items** _(object)_: The configuration of package that will be published. Cannot contain additional properties.
- **`group`** _(string)_: The image is in the group, should be used with the --group option of tag-publish script. Default: `"default"`.
- **`folder`** _(string)_: The folder of the pypi package. Default: `"."`.
- **`build_command`** _(array)_: The command used to do the build.
- **Items** _(string)_
- **`versions_type`** _(array)_: The kind or version that should be published, tag, branch or value of the --version argument of the tag-publish script. Default: `["tag"]`.
- **Items** _(string)_
- <a id="definitions/node"></a>**`node`** _(object)_: Configuration to publish on node.
- <a id="definitions/node"></a>**`node`** _(object)_: Configuration to publish on node. Cannot contain additional properties.
- **`packages`** _(array)_: The configuration of packages that will be published.
- **Items** _(object)_: The configuration of package that will be published.
- **Items** _(object)_: The configuration of package that will be published. Cannot contain additional properties.
- **`group`** _(string)_: The image is in the group, should be used with the --group option of tag-publish script. Default: `"default"`.
- **`folder`** _(string)_: The folder of the node package. Default: `"."`.
- **`versions_type`** _(array)_: The kind or version that should be published, tag, branch or value of the --version argument of the tag-publish script. Default: `["tag"]`.
- **Items** _(string)_
- **`repository`** _(object)_: The packages repository where we should publish the packages. Can contain additional properties. Default: `{"github": {"host": "npm.pkg.github.com"}}`.
- **Additional properties** _(object)_
- **Additional properties** _(object)_: Cannot contain additional properties.
- **`host`** _(string)_: The host of the repository URL.
- **`args`** _(array)_: The arguments to pass to the publish command. Default: `["--provenance", "--access=public"]`.
- **Items** _(string)_
- <a id="definitions/helm"></a>**`helm`** _(object)_: Configuration to publish Helm charts on GitHub release.
- <a id="definitions/helm"></a>**`helm`** _(object)_: Configuration to publish Helm charts on GitHub release. Cannot contain additional properties.
- **`packages`** _(array)_: The configuration of packages that will be published.
- **Items** _(object)_: The configuration of package that will be published.
- **Items** _(object)_: The configuration of package that will be published. Cannot contain additional properties.
- **`group`** _(string)_: The image is in the group, should be used with the --group option of tag-publish script. Default: `"default"`.
- **`folder`** _(string)_: The folder of the pypi package. Default: `"."`.
- **`versions_type`** _(array)_: The kind or version that should be published, tag, branch or value of the --version argument of the tag-publish script. Default: `["tag"]`.
- **Items** _(string)_
- <a id="definitions/transform"></a>**`transform`** _(array)_: A version transformer definition. Default: `[]`.
- **Items** _(object)_
- **Items** _(object)_: Cannot contain additional properties.
- **`from_re`** _(string)_: The from regular expression. Default: `"(.+)"`.
- **`to`** _(string)_: The expand regular expression: https://docs.python.org/3/library/re.html#re.Match.expand. Default: `"\\1"`.
13 changes: 13 additions & 0 deletions tag_publish/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"title": "Docker",
"description": "The configuration used to publish on Docker",
"type": "object",
"additionalProperties": false,
"properties": {
"latest": {
"description": "Publish the latest version on tag latest",
Expand All @@ -23,6 +24,7 @@
"items": {
"title": "Docker image",
"type": "object",
"additionalProperties": false,
"properties": {
"group": {
"description": "The image is in the group, should be used with the --group option of tag-publish script",
Expand Down Expand Up @@ -59,6 +61,7 @@
"additionalProperties": {
"title": "Docker repository",
"type": "object",
"additionalProperties": false,
"properties": {
"host": {
"description": "The host of the repository URL",
Expand Down Expand Up @@ -95,6 +98,7 @@
"title": "pypi",
"description": "Configuration to publish on pypi",
"type": "object",
"additionalProperties": false,
"properties": {
"packages": {
"description": "The configuration of packages that will be published",
Expand All @@ -103,6 +107,7 @@
"title": "pypi package",
"description": "The configuration of package that will be published",
"type": "object",
"additionalProperties": false,
"properties": {
"group": {
"description": "The image is in the group, should be used with the --group option of tag-publish script",
Expand Down Expand Up @@ -141,6 +146,7 @@
"title": "node",
"description": "Configuration to publish on node",
"type": "object",
"additionalProperties": false,
"properties": {
"packages": {
"description": "The configuration of packages that will be published",
Expand All @@ -149,6 +155,7 @@
"title": "node package",
"description": "The configuration of package that will be published",
"type": "object",
"additionalProperties": false,
"properties": {
"group": {
"description": "The image is in the group, should be used with the --group option of tag-publish script",
Expand Down Expand Up @@ -186,6 +193,7 @@
"additionalProperties": {
"title": "Node repository",
"type": "object",
"additionalProperties": false,
"properties": {
"host": {
"description": "The host of the repository URL",
Expand All @@ -209,6 +217,7 @@
"title": "helm",
"description": "Configuration to publish Helm charts on GitHub release",
"type": "object",
"additionalProperties": false,
"properties": {
"packages": {
"description": "The configuration of packages that will be published",
Expand All @@ -217,6 +226,7 @@
"title": "helm package",
"description": "The configuration of package that will be published",
"type": "object",
"additionalProperties": false,
"properties": {
"group": {
"description": "The image is in the group, should be used with the --group option of tag-publish script",
Expand Down Expand Up @@ -252,6 +262,7 @@
"items": {
"title": "Version transform",
"type": "object",
"additionalProperties": false,
"properties": {
"from_re": {
"title": "transform from",
Expand All @@ -277,6 +288,7 @@
"default": {
"pull_request_to_version_re": [{ "to": "pr-\\1" }]
},
"additionalProperties": false,
"properties": {
"branch_to_version": { "$ref": "#/definitions/transform" },
"tag_to_version": { "$ref": "#/definitions/transform" },
Expand All @@ -297,6 +309,7 @@
"description": "Send a dispatch event to an other repository",
"default": {},
"type": "object",
"additionalProperties": false,
"properties": {
"repository": {
"title": "Dispatch repository",
Expand Down

0 comments on commit 7f84316

Please sign in to comment.