diff --git a/.github/workflows/sync.yml b/.github/workflows/sync.yml index f3d6b1187b..e37b894a46 100644 --- a/.github/workflows/sync.yml +++ b/.github/workflows/sync.yml @@ -20,6 +20,10 @@ on: description: "Enable debug/verbose mode (true or false)" type: boolean default: false + blog_post: + description: "link to release blogpost" + type: string + required: true # Cancel if a newer run is started concurrency: @@ -114,6 +118,7 @@ jobs: --pull-request \ --username nf-core-bot \ --github-repository nf-core/${{ matrix.pipeline }} + --blogpost ${{inputs.blogpost}} - name: Upload sync log file artifact if: ${{ always() }} diff --git a/CHANGELOG.md b/CHANGELOG.md index ed78647065..05cb1e2d49 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ ### General +- add optional link to blogpost to sync PR ([#3852](https://github.com/nf-core/tools/pull/3852)) - update multiqc version to fix utils test ([#3853](https://github.com/nf-core/tools/pull/3853)) ### Template diff --git a/nf_core/pipelines/sync.py b/nf_core/pipelines/sync.py index e977d51fc4..94961dd3d4 100644 --- a/nf_core/pipelines/sync.py +++ b/nf_core/pipelines/sync.py @@ -70,6 +70,7 @@ def __init__( gh_username: str | None = None, template_yaml_path: str | None = None, force_pr: bool = False, + blog_post: str = "", ): """Initialise syncing object""" @@ -92,6 +93,7 @@ def __init__( self.gh_username = gh_username self.gh_repo = gh_repo self.pr_url = "" + self.blog_post = blog_post self.config_yml_path, self.config_yml = nf_core.utils.load_tools_config(self.pipeline_dir) assert self.config_yml_path is not None and self.config_yml is not None # mypy @@ -377,7 +379,9 @@ def make_pull_request(self): pr_title = f"Important! Template update for nf-core/tools v{nf_core.__version__}" pr_body_text = ( "Version `{tag}` of [nf-core/tools](https://github.com/nf-core/tools) has just been released with updates to the nf-core template. " - "This automated pull-request attempts to apply the relevant updates to this pipeline.\n\n" + f"For more details, check out the blog post: {self.blog_post}\n\n" + if self.blog_post != "" + else "" "Please make sure to merge this pull-request as soon as possible, " f"resolving any merge conflicts in the `{self.merge_branch}` branch (or your own fork, if you prefer). " "Once complete, make a new minor release of your pipeline.\n\n"