def download(args): """Download the current version of an asset.""" asset = asset_utils.Asset(args.asset_name, asset_utils.MultiStore()) asset.download_current_version(args.target_dir)
def upload(args): """Upload a new version of the asset.""" asset = asset_utils.Asset(args.asset_name, asset_utils.MultiStore()) asset.upload_new_version(args.target_dir, commit=args.commit)
def remove(args): """Remove an asset.""" asset_utils.Asset(args.asset_name, asset_utils.MultiStore()).remove()
def upload(args): """Upload a new version of the asset.""" asset = asset_utils.Asset(args.asset_name, gsutil=args.gsutil) asset.upload_new_version(args.target_dir, commit=args.commit)
def download(args): """Download the current version of an asset.""" asset = asset_utils.Asset(args.asset_name, gsutil=args.gsutil) asset.download_current_version(args.target_dir)
def remove(args): """Remove an asset.""" asset_utils.Asset(args.asset_name).remove()
def _asset(args): """Return asset_utils.Asset based on args.""" return asset_utils.Asset(args.asset_name, _store(args))