From 9770ba07c2b5fff0cae87a973d4a230d9344ddc2 Mon Sep 17 00:00:00 2001 From: Jens Langhammer Date: Sat, 10 Sep 2022 13:25:01 +0200 Subject: [PATCH] ci: remove duplicate helper script Signed-off-by: Jens Langhammer --- .../comment-pr-instructions/action.yml | 33 +------------------ 1 file changed, 1 insertion(+), 32 deletions(-) diff --git a/.github/actions/comment-pr-instructions/action.yml b/.github/actions/comment-pr-instructions/action.yml index 187d71f8e..21c8d1d4e 100644 --- a/.github/actions/comment-pr-instructions/action.yml +++ b/.github/actions/comment-pr-instructions/action.yml @@ -11,38 +11,7 @@ runs: steps: - name: Generate config id: ev - shell: python - run: | - """Helper script to get the actual branch name, docker safe""" - import os - from time import time - - env_pr_branch = "GITHUB_HEAD_REF" - default_branch = "GITHUB_REF" - sha = "GITHUB_SHA" - - branch_name = os.environ[default_branch] - if os.environ.get(env_pr_branch, "") != "": - branch_name = os.environ[env_pr_branch] - - should_build = str(os.environ.get("DOCKER_USERNAME", "") != "").lower() - - print("##[set-output name=branchName]%s" % branch_name) - print( - "##[set-output name=branchNameContainer]%s" - % branch_name.replace("refs/heads/", "").replace("/", "-") - ) - print("##[set-output name=timestamp]%s" % int(time())) - print("##[set-output name=sha]%s" % os.environ[sha]) - print("##[set-output name=shouldBuild]%s" % should_build) - - import configparser - parser = configparser.ConfigParser() - parser.read(".bumpversion.cfg") - version = parser.get("bumpversion", "current_version") - version_family = ".".join(version.split(".")[:-1]) - print("##[set-output name=version]%s" % version) - print("##[set-output name=versionFamily]%s" % version_family) + uses: ./.github/actions/docker-push-variables - name: Find Comment uses: peter-evans/find-comment@v2 id: fc