mirror of
https://github.com/deadc0de6/dotdrop.git
synced 2026-02-16 21:24:10 +00:00
add -w --workers cli switch
This commit is contained in:
@@ -54,7 +54,7 @@ USAGE = """
|
|||||||
Usage:
|
Usage:
|
||||||
dotdrop install [-VbtfndDa] [-c <path>] [-p <profile>] [<key>...]
|
dotdrop install [-VbtfndDa] [-c <path>] [-p <profile>] [<key>...]
|
||||||
dotdrop import [-Vbdf] [-c <path>] [-p <profile>] [-s <path>]
|
dotdrop import [-Vbdf] [-c <path>] [-p <profile>] [-s <path>]
|
||||||
[-l <link>] <path>...
|
[-w <nb>] [-l <link>] <path>...
|
||||||
dotdrop compare [-LVb] [-c <path>] [-p <profile>]
|
dotdrop compare [-LVb] [-c <path>] [-p <profile>]
|
||||||
[-C <file>...] [-i <pattern>...]
|
[-C <file>...] [-i <pattern>...]
|
||||||
dotdrop update [-VbfdkP] [-c <path>] [-p <profile>]
|
dotdrop update [-VbfdkP] [-c <path>] [-p <profile>]
|
||||||
@@ -86,6 +86,7 @@ Options:
|
|||||||
-t --temp Install to a temporary directory for review.
|
-t --temp Install to a temporary directory for review.
|
||||||
-T --template Only template dotfiles.
|
-T --template Only template dotfiles.
|
||||||
-V --verbose Be verbose.
|
-V --verbose Be verbose.
|
||||||
|
-w --workers=<nb> Number of concurrent workers [default: 1].
|
||||||
-v --version Show version.
|
-v --version Show version.
|
||||||
-h --help Show this screen.
|
-h --help Show this screen.
|
||||||
""".format(BANNER, PROFILE)
|
""".format(BANNER, PROFILE)
|
||||||
@@ -237,8 +238,7 @@ class Options(AttrMonitor):
|
|||||||
self.install_default_actions_post = [a for a in self.default_actions
|
self.install_default_actions_post = [a for a in self.default_actions
|
||||||
if a.kind == Action.post]
|
if a.kind == Action.post]
|
||||||
self.install_ignore = self.instignore
|
self.install_ignore = self.instignore
|
||||||
# TODO add as option
|
self.install_parallel = int(self.args['--workers'])
|
||||||
self.install_parallel = True
|
|
||||||
# "compare" specifics
|
# "compare" specifics
|
||||||
self.compare_focus = self.args['--file']
|
self.compare_focus = self.args['--file']
|
||||||
self.compare_ignore = self.args['--ignore']
|
self.compare_ignore = self.args['--ignore']
|
||||||
|
|||||||
@@ -131,6 +131,7 @@ def _fake_args():
|
|||||||
args['--grepable'] = False
|
args['--grepable'] = False
|
||||||
args['--as'] = None
|
args['--as'] = None
|
||||||
args['--file-only'] = False
|
args['--file-only'] = False
|
||||||
|
args['--workers'] = 1
|
||||||
# cmds
|
# cmds
|
||||||
args['profiles'] = False
|
args['profiles'] = False
|
||||||
args['files'] = False
|
args['files'] = False
|
||||||
|
|||||||
Reference in New Issue
Block a user