Add --no-locker param

This commit is contained in:
Dmitry Petrov
2017-04-18 09:08:40 -07:00
parent 3e5c7611aa
commit 378b56a303
6 changed files with 56 additions and 32 deletions
+6
View File
@@ -51,11 +51,17 @@ class CmdBase(object):
def set_skip_git_actions(self, parser):
parser.add_argument('--skip-git-actions', '-s', action='store_true',
help='Skip all git actions including reproducibility check and commits')
parser.add_argument('--no-lock', '-L', action='store_true', default=False,
help='Do not set DVC locker')
@property
def skip_git_actions(self):
return self.parsed_args.skip_git_actions
@property
def is_locker(self):
return not self.parsed_args.no_lock
def commit_if_needed(self, message, error=False):
if error or self.skip_git_actions:
self.not_committed_changes_warning()