Skip to content

Commit

Permalink
Fixes to create workflow release command and upgrade icav2 cli plugin…
Browse files Browse the repository at this point in the history
… versions
  • Loading branch information
alexiswl committed Jun 24, 2024
1 parent c197af3 commit e5625fd
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ ARG CONDA_USER_ID=1000
ARG CONDA_ENV_NAME="cwl-ica"
ARG YQ_VERSION="v4.35.2"
ARG ICAV2_CLI_VERSION="2.26.0"
ARG ICAV2_PLUGINS_CLI_VERSION="v2.27.0.dev20240624111939"
ARG ICAV2_PLUGINS_CLI_VERSION="v2.27.0.dev20240624161340"
ARG ICAV2_PLUGINS_CLI_CONDA_PYTHON_VERSION="3.12"
ARG ICAV2_PLUGINS_CLI_CONDA_ENV_NAME="python3.12"
ARG CURL_VERSION="7.81.0"
Expand Down
13 changes: 7 additions & 6 deletions src/cwl_ica/subcommands/creators/create_workflow_release.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,8 @@ def git_checks(self):
get_branch_name_returncode, get_branch_name_stdout, get_branch_name_stderr = run_subprocess_proc(
[
"git", "rev-parse", "--abbrev-ref", "HEAD"
]
],
capture_output=True
)
if get_branch_name_returncode != 0:
logger.error("Please ensure you are on the main branch before continuing")
Expand All @@ -131,16 +132,16 @@ def git_checks(self):
raise CheckArgumentError

# Check we're in sync with the remote branch
get_remote_branch_proc = run_subprocess_proc(
get_remote_branch_returncode, get_remote_branch_stdout, get_remote_branch_stderr = run_subprocess_proc(
[
"git", "rev-parse", "--abbrev-ref", "--symbolic-full-name", "@{u}"
],
capture_output=True
)
if get_remote_branch_proc.returncode != 0:
if get_remote_branch_returncode != 0:
logger.error("Could not get the upstream branch for this ")
raise CheckArgumentError
remote_branch = get_remote_branch_proc.stdout.strip()
remote_branch = get_remote_branch_stdout.strip()

# Check diffs between remote and local
diff_returncode, diff_stdout, diff_stderr = run_subprocess_proc(
Expand All @@ -157,7 +158,7 @@ def generate_tag(self):
logger.info("Generating tag")
tag_returncode, tag_stdout, tag_stderr = run_subprocess_proc(
[
"git", "tag", self.tag
"git", "tag", "--force", self.tag
],
capture_output=True
)
Expand All @@ -174,7 +175,7 @@ def __call__(self):
logger.info(f"Pushing tag {self.tag}")
push_tag_returncode, push_tag_stdout, push_tag_stderr = run_subprocess_proc(
[
"git", "push", "origin", self.tag
"git", "push", "origin", "--force", self.tag
],
capture_output=True
)
Expand Down

0 comments on commit e5625fd

Please sign in to comment.