From 26d01280e5bd4b24ae028ba706b3a18e7ee1f863 Mon Sep 17 00:00:00 2001 From: mashehu Date: Mon, 13 Nov 2023 13:11:40 +0100 Subject: [PATCH] apply code suggestions --- nf_core/bump_version.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/nf_core/bump_version.py b/nf_core/bump_version.py index 3f1616954b..9f47c433d1 100644 --- a/nf_core/bump_version.py +++ b/nf_core/bump_version.py @@ -5,7 +5,7 @@ import logging import re from pathlib import Path -from typing import Union +from typing import List, Union import rich.console @@ -42,7 +42,7 @@ def bump_pipeline_version(pipeline_obj: Pipeline, new_version: str) -> None: [ ( rf"(version\s*=\s*['\"]){re.escape(current_version)}(['\"])", - rf"\g<1>{new_version}\g<2>", + rf"\g<1>{new_version}", ) ], ) @@ -140,7 +140,7 @@ def bump_nextflow_version(pipeline_obj: Pipeline, new_version: str) -> None: ) -def update_file_version(filename: Union[str, Path], pipeline_obj: Pipeline, patterns: list[tuple[str, str]]) -> None: +def update_file_version(filename: Union[str, Path], pipeline_obj: Pipeline, patterns: List[tuple[str, str]]) -> None: """Updates the version number in a requested file. Args: