Merge pull request #1045 from efiop/master

dvc: print command specific help
This commit is contained in:
Ruslan Kuprieiev
2018-08-23 07:39:37 +03:00
committed by GitHub
+5 -1
View File
@@ -785,7 +785,11 @@ def parse_args(argv=None):
cwd = os.curdir
path = os.path.join(cwd, 'Dvcfile')
if not os.path.exists(path):
parser.error("default target '{}' does not exist.".format(path))
msg = "default target '{}' does not exist.".format(path)
if issubclass(args.func, CmdRepro):
repro_parser.error(msg)
elif issubclass(args.func, CmdPipelineShow):
pipeline_show_parser.error(msg)
args.targets = ['Dvcfile']
return args