def sync_source_option(func):
"""
Add the sync source option to the decorated command func.
:param func: Click CLI command to decorate
:return: decorated CLI command
"""
return option(
'--src',
'-s',
'sync_source',
type=Path(
exists=True,
file_okay=False,
resolve_path=True,
),
help='Local directory from which to sync. Optional.',
)(func)
评论列表
文章目录