UNPKG

zapier-platform-cli

Version:

The CLI for apps in the Zapier Developer Platform.

19 lines (16 loc) 1.03 kB
'use strict'; var constants = require('../constants'); var utils = require('../utils'); var upload = function upload(context) { var zipPath = constants.BUILD_PATH; context.line('Preparing to upload a new version.\n'); return utils.upload(zipPath, '.').then(function () { context.line('\nUpload of ' + constants.BUILD_PATH + ' complete! Try `zapier versions` now!'); }); }; upload.argsSpec = []; upload.argOptsSpec = {}; upload.help = 'Upload the last build as a version.'; upload.example = 'zapier upload'; upload.docs = '\nUpload the zip file already built by `zapier build` in build/build.zip. The version and other app details are read by Zapier from the zip file.\n\n> Note: we generally recommend using `zapier push` which does both `zapier build && zapier upload` in one step.\n\n' + '```' + 'bash\n$ zapier upload\n# Preparing to upload a new version.\n#\n# Uploading version 1.0.0 - done!\n#\n# Upload of build/build.zip complete! Try `zapier versions` now!\n' + '```' + '\n'; module.exports = upload;