diff options
author | Phil Dawson <phil.dawson@codethink.co.uk> | 2018-12-12 11:40:30 +0000 |
---|---|---|
committer | Phil Dawson <phil.dawson@codethink.co.uk> | 2018-12-12 13:55:19 +0000 |
commit | d55b9e398ca4d95e2ffe70580cddf7911c161d20 (patch) | |
tree | 7d57ed6c67b96976dbe986268193eeb8d1f746a0 /buildstream/_frontend | |
parent | a5a53ddd243f0da0c485d539591d8a11e5bd5262 (diff) | |
download | buildstream-d55b9e398ca4d95e2ffe70580cddf7911c161d20.tar.gz |
Add --tar option to source-checkout command
This commit is part of the work towards #672
Diffstat (limited to 'buildstream/_frontend')
-rw-r--r-- | buildstream/_frontend/cli.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/buildstream/_frontend/cli.py b/buildstream/_frontend/cli.py index 4900b28a7..ae640753d 100644 --- a/buildstream/_frontend/cli.py +++ b/buildstream/_frontend/cli.py @@ -733,11 +733,14 @@ def checkout(app, element, location, force, deps, integrate, hardlinks, tar): help='The dependencies whose sources to checkout (default: none)') @click.option('--fetch', 'fetch_', default=False, is_flag=True, help='Fetch elements if they are not fetched') +@click.option('--tar', 'tar', default=False, is_flag=True, + help='Create a tarball from the element\'s sources instead of a ' + 'file tree.') @click.argument('element', required=False, type=click.Path(readable=False)) @click.argument('location', type=click.Path(), required=False) @click.pass_obj -def source_checkout(app, element, location, deps, fetch_, except_): +def source_checkout(app, element, location, deps, fetch_, except_, tar): """Checkout sources of an element to the specified location """ if not element and not location: @@ -759,7 +762,8 @@ def source_checkout(app, element, location, deps, fetch_, except_): location=location, deps=deps, fetch=fetch_, - except_targets=except_) + except_targets=except_, + tar=tar) ################################################################## |