diff --git a/tag_publish/cli.py b/tag_publish/cli.py index 2aa810d..ab8feeb 100644 --- a/tag_publish/cli.py +++ b/tag_publish/cli.py @@ -506,7 +506,7 @@ def _handle_helm_publish( ) -> bool: success = True helm_config = config.get("helm", {}) - if helm_config.get("folders") and version_type in helm_config.get( + if helm_config.get("packages") and version_type in helm_config.get( "versions", tag_publish.configuration.HELM_VERSIONS_DEFAULT ): tag_publish.download_application("helm/chart-releaser") @@ -550,22 +550,13 @@ def _handle_helm_publish( f'{group}' ) if package.get("group", tag_publish.configuration.HELM_PACKAGE_GROUP_DEFAULT) == group: - print( - f'version_type: {version_type} in ' - f'{helm_config.get("versions", tag_publish.configuration.HELM_VERSIONS_DEFAULT)}' - ) - publish = version_type in helm_config.get( - "versions", tag_publish.configuration.HELM_VERSIONS_DEFAULT - ) - print(publish) - if publish: - folder = package.get("folder", tag_publish.configuration.HELM_PACKAGE_FOLDER_DEFAULT) - if dry_run: - print(f"Publishing '{folder}' to helm, skipping (dry run)") - else: - token = os.environ["GITHUB_TOKEN"] - success &= tag_publish.publish.helm(folder, version, owner, repo, commit_sha, token) - published_payload.append({"type": "helm", "folder": folder}) + folder = package.get("folder", tag_publish.configuration.HELM_PACKAGE_FOLDER_DEFAULT) + if dry_run: + print(f"Publishing '{folder}' to helm, skipping (dry run)") + else: + token = os.environ["GITHUB_TOKEN"] + success &= tag_publish.publish.helm(folder, version, owner, repo, commit_sha, token) + published_payload.append({"type": "helm", "folder": folder}) return success