Skip to content

Commit f856746

Browse files
committed
enh: cli version
1 parent 507c514 commit f856746

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

nipype/scripts/cli.py

+5
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
PythonModule,
1616
check_not_none,)
1717

18+
from .. import __version__
1819

1920
# declare the CLI group
2021
@click.group(context_settings=CONTEXT_SETTINGS)
@@ -151,6 +152,10 @@ def run(ctx, module, interface, list, help):
151152
args = iface_parser.parse_args(args=ctx.args)
152153
run_instance(node, args)
153154

155+
@cli.command(context_settings=CONTEXT_SETTINGS)
156+
def version():
157+
"""Print current version of Nipype."""
158+
click.echo(__version__)
154159

155160
@cli.group()
156161
def convert():

0 commit comments

Comments
 (0)