Skip to content

Commit

Permalink
kas: add forgotten tag key to repos defaults
Browse files Browse the repository at this point in the history
Commit 75f4767 added `tag` to `repos` config but forgot to add it to `defaults`.

This commit adds the missing key in schema-kas.json, repos.py and format-changelog.rst.
It also fixes the format changelog for v15.

Signed-off-by: Félix Piédallu <[email protected]>
[Jan: update also __file_version__]
Signed-off-by: Jan Kiszka <[email protected]>
  • Loading branch information
Salamandar authored and jan-kiszka committed Jan 10, 2024
1 parent 365cec1 commit afe6fe8
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 3 deletions.
11 changes: 10 additions & 1 deletion docs/format-changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -153,4 +153,13 @@ Added
~~~~~

- The key ``tag`` is introduced as a complement to ``commit`` and ``branch``
in ``repos`` and ``default``.
in ``repos``.

Version 16
----------

Fixed
~~~~~

- The key ``tag`` introduced in v15 was not supported in ``defaults``.
It's now added.
4 changes: 4 additions & 0 deletions docs/userguide.rst
Original file line number Diff line number Diff line change
Expand Up @@ -371,6 +371,10 @@ Configuration reference
Sets the default ``branch`` property applied to all repositories that
do not override this.

``tag``: string [optional]
Sets the default ``tag`` property applied to all repositories that
do not override this.

``patches``: dict [optional]
This key can contain default values for some repository patch
properties. If a default value is set for a patch property it may
Expand Down
2 changes: 1 addition & 1 deletion kas/__version__.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,5 @@
__version__ = '4.1'

# Please update docs/format-changelog.rst when changing the file version.
__file_version__ = 15
__file_version__ = 16
__compatible_file_version__ = 1
2 changes: 1 addition & 1 deletion kas/repos.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ def factory(name, repo_config, repo_defaults, repo_fallback_path,
name = repo_config.get('name', name)
repo_type = repo_config.get('type', 'git')
commit = repo_config.get('commit', None)
tag = repo_config.get('tag', None)
tag = repo_config.get('tag', repo_defaults.get('tag', None))
branch = repo_config.get('branch', repo_defaults.get('branch', None))
refspec = repo_config.get('refspec',
repo_defaults.get('refspec', None))
Expand Down
3 changes: 3 additions & 0 deletions kas/schema-kas.json
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,9 @@
"branch": {
"type": "string"
},
"tag": {
"type": "string"
},
"refspec": {
"type": "string"
},
Expand Down

0 comments on commit afe6fe8

Please sign in to comment.