From 6702e76b58d51d16b2203f751974a9cf2db518ab Mon Sep 17 00:00:00 2001 From: mashehu Date: Mon, 12 Jan 2026 20:12:58 +0100 Subject: [PATCH 1/2] add aliases to more commands --- nf_core/__main__.py | 44 ++++++++++++++++++++++---------------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/nf_core/__main__.py b/nf_core/__main__.py index de682be24f..1194a9460a 100644 --- a/nf_core/__main__.py +++ b/nf_core/__main__.py @@ -203,7 +203,7 @@ def pipelines(ctx): # nf-core pipelines create -@pipelines.command("create") +@pipelines.command("create", aliases=["c"]) @click.pass_context @click.option( "-n", @@ -231,7 +231,7 @@ def command_pipelines_create(ctx, name, description, author, version, force, out # nf-core pipelines lint -@pipelines.command("lint") +@pipelines.command("lint", aliases=["l"]) @click.option( "-d", "--dir", @@ -307,7 +307,7 @@ def command_pipelines_lint( # nf-core pipelines download -@pipelines.command("download") +@pipelines.command("download", aliases=["d"]) @click.argument( "pipeline", required=False, @@ -522,7 +522,7 @@ def command_pipelines_launch( # nf-core pipelines list -@pipelines.command("list") +@pipelines.command("list", aliases=["ls"]) @click.argument("keywords", required=False, nargs=-1, metavar="") @click.option( "-s", @@ -625,7 +625,7 @@ def command_pipelines_sync( # nf-core pipelines bump-version -@pipelines.command("bump-version") +@pipelines.command("bump-version", aliases=["bump", "bv", "b"]) @click.pass_context @click.argument("new_version", required=True, metavar="") @click.option( @@ -769,7 +769,7 @@ def command_pipelines_schema_build(directory, no_prompts, web_only, url): # nf-core pipelines schema lint -@pipeline_schema.command("lint") +@pipeline_schema.command("lint", aliases=["l"]) @click.option( "-d", "--dir", @@ -879,7 +879,7 @@ def modules(ctx, git_remote, branch, no_pull): # nf-core modules list subcommands -@modules.group("list") +@modules.group("list", aliases=["ls"]) @click.pass_context def modules_list(ctx): """ @@ -921,7 +921,7 @@ def command_modules_list_local(ctx, keywords, json, directory): # pylint: disab # nf-core modules install -@modules.command("install") +@modules.command("install", aliases=["add", "i"]) @click.pass_context @click.argument( "tool", @@ -962,7 +962,7 @@ def command_modules_install(ctx, tool, directory, prompt, force, sha): # nf-core modules update -@modules.command("update") +@modules.command("update", aliases=["up", "u"]) @click.pass_context @click.argument( "tool", @@ -1073,7 +1073,7 @@ def command_modules_patch(ctx, tool, directory, remove): # nf-core modules remove -@modules.command("remove") +@modules.command("remove", aliases=["uninstall", "rm", "r"]) @click.pass_context @click.argument( "tool", @@ -1099,7 +1099,7 @@ def command_modules_remove(ctx, directory, tool): # nf-core modules create -@modules.command("create") +@modules.command("create", aliases=["c"]) @click.pass_context @click.argument("tool", type=str, required=False, metavar=" or ") @click.option("-d", "--dir", "directory", type=click.Path(exists=True), default=".", metavar="") @@ -1199,7 +1199,7 @@ def command_modules_create( # nf-core modules test -@modules.command("test") +@modules.command("test", aliases=["t"]) @click.pass_context @click.argument( "tool", @@ -1261,7 +1261,7 @@ def command_modules_test(ctx, tool, directory, no_prompts, update, once, profile # nf-core modules lint -@modules.command("lint") +@modules.command("lint", aliases=["l"]) @click.pass_context @click.argument( "tool", @@ -1348,7 +1348,7 @@ def command_modules_info(ctx, tool, directory): # nf-core modules bump-versions -@modules.command("bump-versions") +@modules.command("bump-versions", aliases=["bump-version", "bump", "bv", "b"]) @click.pass_context @click.argument( "tool", @@ -1418,7 +1418,7 @@ def subworkflows(ctx, git_remote, branch, no_pull): # nf-core subworkflows create -@subworkflows.command("create") +@subworkflows.command("create", aliases=["c"]) @click.pass_context @click.argument("subworkflow", type=str, required=False, metavar="subworkflow name") @click.option("-d", "--dir", "directory", type=click.Path(exists=True), default=".", metavar="") @@ -1450,7 +1450,7 @@ def command_subworkflows_create(ctx, subworkflow, directory, author, force, migr # nf-core subworkflows test -@subworkflows.command("test") +@subworkflows.command("test", aliases=["t"]) @click.pass_context @click.argument( "subworkflow", @@ -1503,7 +1503,7 @@ def command_subworkflows_test(ctx, subworkflow, directory, no_prompts, update, o # nf-core subworkflows list subcommands -@subworkflows.group("list") +@subworkflows.group("list", aliases=["ls"]) @click.pass_context def subworkflows_list(ctx): """ @@ -1545,7 +1545,7 @@ def command_subworkflows_list_local(ctx, keywords, json, directory): # pylint: # nf-core subworkflows lint -@subworkflows.command("lint") +@subworkflows.command("lint", aliases=["l"]) @click.pass_context @click.argument( "subworkflow", @@ -1627,7 +1627,7 @@ def command_subworkflows_info(ctx, subworkflow, directory): # nf-core subworkflows install -@subworkflows.command("install") +@subworkflows.command("install", aliases=["add", "i"]) @click.pass_context @click.argument( "subworkflow", @@ -1718,7 +1718,7 @@ def subworkflows_patch(ctx, subworkflow, dir, remove): # nf-core subworkflows remove -@subworkflows.command("remove") +@subworkflows.command("remove", aliases=["uninstall", "rm", "r"]) @click.pass_context @click.argument( "subworkflow", @@ -1744,7 +1744,7 @@ def command_subworkflows_remove(ctx, directory, subworkflow): # nf-core subworkflows update -@subworkflows.command("update") +@subworkflows.command("update", aliases=["up", "u"]) @click.pass_context @click.argument( "subworkflow", @@ -1876,7 +1876,7 @@ def command_test_dataset_search(ctx, branch, generate_nf_path, generate_dl_url, # nf-core test-dataset search -@test_datasets.command("list") +@test_datasets.command("list", aliases=["ls"]) @click.pass_context @click.option("-b", "--branch", type=str, help="Branch in the test-datasets repository to reduce search to") @click.option( From 750b79fdbe004b26487b519ebd6d27bbcc473c6c Mon Sep 17 00:00:00 2001 From: nf-core-bot Date: Mon, 12 Jan 2026 19:24:56 +0000 Subject: [PATCH 2/2] [automated] Update CHANGELOG.md --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index d5779b59a3..94ab4b24e3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -27,6 +27,7 @@ - fix test for linting for version.yml ([#3947](https://github.com/nf-core/tools/pull/3947)) - more fixes for incorrect parsing of version statement ([#3973](https://github.com/nf-core/tools/pull/3973)) +- Add aliases to common sub-subcommands like `install`, `lint`, etc. ([#3980](https://github.com/nf-core/tools/pull/3980)) ### Modules