UNPKG

bit-bin

Version:

<a href="https://opensource.org/licenses/Apache-2.0"><img alt="apache" src="https://img.shields.io/badge/License-Apache%202.0-blue.svg"></a> <a href="https://github.com/teambit/bit/blob/master/CONTRIBUTING.md"><img alt="prs" src="https://img.shields.io/b

48 lines (38 loc) 1.52 kB
"use strict"; var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault"); Object.defineProperty(exports, "__esModule", { value: true }); exports.default = _default; function _chalk() { const data = _interopRequireDefault(require("chalk")); _chalk = function () { return data; }; return data; } /** * schema for forking components */ function _default(bitIds, remote) { return { properties: { shouldFork: { required: true, description: `bit is about to fork the following components and export them to ${_chalk().default.bold(remote)}. \t${bitIds.map(id => _chalk().default.bold(id.toStringWithoutVersion())).join('\n\t')} also, if they're staged, bit will not change their status to exported unless '--set-current-scope' flag is used. there are additional flags for the 'export' command to specifically handle forking components: 1. '--include-dependencies' exports all dependencies to the destination alongside the component. 2. '--set-current-scope' sets your workspace to use the destination scope as the main remote for the component. 3. '--rewire' changes all dependencies to point to the new destination. would you like to proceed with forking the components? (yes/no)`, message: 'please type yes or no.', type: 'string', conform(value) { return value.toLowerCase() === 'y' || value.toLowerCase() === 'n' || value.toLowerCase() === 'yes' || value.toLowerCase() === 'no'; } } } }; }