@strapi/cloud-cli 0.0.0-experimental.254a2c362362c7aeaa3805bc097faf2634b76414
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +22 -0
- package/README.md +3 -0
- package/bin/index.js +7 -0
- package/dist/bin.d.ts +5 -0
- package/dist/bin.d.ts.map +1 -0
- package/dist/bin.js +172 -0
- package/dist/bin.js.map +1 -0
- package/dist/config/api.d.ts +4 -0
- package/dist/config/api.d.ts.map +1 -0
- package/dist/config/local.d.ts +8 -0
- package/dist/config/local.d.ts.map +1 -0
- package/dist/create-project/action.d.ts +4 -0
- package/dist/create-project/action.d.ts.map +1 -0
- package/dist/create-project/index.d.ts +9 -0
- package/dist/create-project/index.d.ts.map +1 -0
- package/dist/deploy-project/action.d.ts +4 -0
- package/dist/deploy-project/action.d.ts.map +1 -0
- package/dist/deploy-project/command.d.ts +7 -0
- package/dist/deploy-project/command.d.ts.map +1 -0
- package/dist/deploy-project/index.d.ts +11 -0
- package/dist/deploy-project/index.d.ts.map +1 -0
- package/dist/index.d.ts +13 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +1004 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +948 -0
- package/dist/index.mjs.map +1 -0
- package/dist/login/action.d.ts +4 -0
- package/dist/login/action.d.ts.map +1 -0
- package/dist/login/command.d.ts +7 -0
- package/dist/login/command.d.ts.map +1 -0
- package/dist/login/index.d.ts +11 -0
- package/dist/login/index.d.ts.map +1 -0
- package/dist/logout/action.d.ts +4 -0
- package/dist/logout/action.d.ts.map +1 -0
- package/dist/logout/command.d.ts +7 -0
- package/dist/logout/command.d.ts.map +1 -0
- package/dist/logout/index.d.ts +11 -0
- package/dist/logout/index.d.ts.map +1 -0
- package/dist/services/build-logs.d.ts +4 -0
- package/dist/services/build-logs.d.ts.map +1 -0
- package/dist/services/cli-api.d.ts +37 -0
- package/dist/services/cli-api.d.ts.map +1 -0
- package/dist/services/index.d.ts +5 -0
- package/dist/services/index.d.ts.map +1 -0
- package/dist/services/logger.d.ts +22 -0
- package/dist/services/logger.d.ts.map +1 -0
- package/dist/services/notification.d.ts +3 -0
- package/dist/services/notification.d.ts.map +1 -0
- package/dist/services/strapi-info-save.d.ts +15 -0
- package/dist/services/strapi-info-save.d.ts.map +1 -0
- package/dist/services/token.d.ts +12 -0
- package/dist/services/token.d.ts.map +1 -0
- package/dist/types.d.ts +33 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/utils/compress-files.d.ts +4 -0
- package/dist/utils/compress-files.d.ts.map +1 -0
- package/dist/utils/helpers.d.ts +3 -0
- package/dist/utils/helpers.d.ts.map +1 -0
- package/dist/utils/pkg.d.ts +121 -0
- package/dist/utils/pkg.d.ts.map +1 -0
- package/dist/utils/tests/compress-files.test.d.ts +2 -0
- package/dist/utils/tests/compress-files.test.d.ts.map +1 -0
- package/package.json +78 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
Copyright (c) 2015-present Strapi Solutions SAS
|
|
2
|
+
|
|
3
|
+
Portions of the Strapi software are licensed as follows:
|
|
4
|
+
|
|
5
|
+
* All software that resides under an "ee/" directory (the “EE Software”), if that directory exists, is licensed under the license defined in "ee/LICENSE".
|
|
6
|
+
|
|
7
|
+
* All software outside of the above-mentioned directories or restrictions above is available under the "MIT Expat" license as set forth below.
|
|
8
|
+
|
|
9
|
+
MIT Expat License
|
|
10
|
+
|
|
11
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
12
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
13
|
+
in the Software without restriction, including without limitation the rights
|
|
14
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
15
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
16
|
+
furnished to do so, subject to the following conditions:
|
|
17
|
+
|
|
18
|
+
The above copyright notice and this permission notice shall be included in all
|
|
19
|
+
copies or substantial portions of the Software.
|
|
20
|
+
|
|
21
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
22
|
+
SOFTWARE.
|
package/README.md
ADDED
package/bin/index.js
ADDED
package/dist/bin.d.ts
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
declare function buildStrapiCloudCommand(argv?: string[], command?: Command): void;
|
|
3
|
+
declare function runStrapiCloudCommand(argv?: string[], command?: Command): void;
|
|
4
|
+
export { buildStrapiCloudCommand, runStrapiCloudCommand };
|
|
5
|
+
//# sourceMappingURL=bin.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bin.d.ts","sourceRoot":"","sources":["../src/bin.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAKpC,iBAAS,uBAAuB,CAAC,IAAI,WAAe,EAAE,OAAO,UAAgB,QAyC5E;AAED,iBAAS,qBAAqB,CAAC,IAAI,WAAe,EAAE,OAAO,UAAgB,QAG1E;AAED,OAAO,EAAE,uBAAuB,EAAE,qBAAqB,EAAE,CAAC"}
|
package/dist/bin.js
ADDED
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
+
const commander = require("commander");
|
|
4
|
+
const chalk = require("chalk");
|
|
5
|
+
const ora = require("ora");
|
|
6
|
+
const cliProgress = require("cli-progress");
|
|
7
|
+
const index_ts = require("./index.ts");
|
|
8
|
+
const _interopDefault = (e) => e && e.__esModule ? e : { default: e };
|
|
9
|
+
function _interopNamespace(e) {
|
|
10
|
+
if (e && e.__esModule)
|
|
11
|
+
return e;
|
|
12
|
+
const n = Object.create(null, { [Symbol.toStringTag]: { value: "Module" } });
|
|
13
|
+
if (e) {
|
|
14
|
+
for (const k in e) {
|
|
15
|
+
if (k !== "default") {
|
|
16
|
+
const d = Object.getOwnPropertyDescriptor(e, k);
|
|
17
|
+
Object.defineProperty(n, k, d.get ? d : {
|
|
18
|
+
enumerable: true,
|
|
19
|
+
get: () => e[k]
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
n.default = e;
|
|
25
|
+
return Object.freeze(n);
|
|
26
|
+
}
|
|
27
|
+
const chalk__default = /* @__PURE__ */ _interopDefault(chalk);
|
|
28
|
+
const ora__default = /* @__PURE__ */ _interopDefault(ora);
|
|
29
|
+
const cliProgress__namespace = /* @__PURE__ */ _interopNamespace(cliProgress);
|
|
30
|
+
const createLogger = (options = {}) => {
|
|
31
|
+
const { silent = false, debug = false, timestamp = true } = options;
|
|
32
|
+
const state = { errors: 0, warning: 0 };
|
|
33
|
+
return {
|
|
34
|
+
get warnings() {
|
|
35
|
+
return state.warning;
|
|
36
|
+
},
|
|
37
|
+
get errors() {
|
|
38
|
+
return state.errors;
|
|
39
|
+
},
|
|
40
|
+
debug(...args) {
|
|
41
|
+
if (silent || !debug) {
|
|
42
|
+
return;
|
|
43
|
+
}
|
|
44
|
+
console.log(
|
|
45
|
+
chalk__default.default.cyan(`[DEBUG]${timestamp ? ` [${(/* @__PURE__ */ new Date()).toISOString()}]` : ""}`),
|
|
46
|
+
...args
|
|
47
|
+
);
|
|
48
|
+
},
|
|
49
|
+
info(...args) {
|
|
50
|
+
if (silent) {
|
|
51
|
+
return;
|
|
52
|
+
}
|
|
53
|
+
console.info(
|
|
54
|
+
chalk__default.default.blue(`[INFO]${timestamp ? ` [${(/* @__PURE__ */ new Date()).toISOString()}]` : ""}`),
|
|
55
|
+
...args
|
|
56
|
+
);
|
|
57
|
+
},
|
|
58
|
+
log(...args) {
|
|
59
|
+
if (silent) {
|
|
60
|
+
return;
|
|
61
|
+
}
|
|
62
|
+
console.info(chalk__default.default.blue(`${timestamp ? ` [${(/* @__PURE__ */ new Date()).toISOString()}]` : ""}`), ...args);
|
|
63
|
+
},
|
|
64
|
+
success(...args) {
|
|
65
|
+
if (silent) {
|
|
66
|
+
return;
|
|
67
|
+
}
|
|
68
|
+
console.info(
|
|
69
|
+
chalk__default.default.green(`[SUCCESS]${timestamp ? ` [${(/* @__PURE__ */ new Date()).toISOString()}]` : ""}`),
|
|
70
|
+
...args
|
|
71
|
+
);
|
|
72
|
+
},
|
|
73
|
+
warn(...args) {
|
|
74
|
+
state.warning += 1;
|
|
75
|
+
if (silent) {
|
|
76
|
+
return;
|
|
77
|
+
}
|
|
78
|
+
console.warn(
|
|
79
|
+
chalk__default.default.yellow(`[WARN]${timestamp ? ` [${(/* @__PURE__ */ new Date()).toISOString()}]` : ""}`),
|
|
80
|
+
...args
|
|
81
|
+
);
|
|
82
|
+
},
|
|
83
|
+
error(...args) {
|
|
84
|
+
state.errors += 1;
|
|
85
|
+
if (silent) {
|
|
86
|
+
return;
|
|
87
|
+
}
|
|
88
|
+
console.error(
|
|
89
|
+
chalk__default.default.red(`[ERROR]${timestamp ? ` [${(/* @__PURE__ */ new Date()).toISOString()}]` : ""}`),
|
|
90
|
+
...args
|
|
91
|
+
);
|
|
92
|
+
},
|
|
93
|
+
// @ts-expect-error – returning a subpart of ora is fine because the types tell us what is what.
|
|
94
|
+
spinner(text) {
|
|
95
|
+
if (silent) {
|
|
96
|
+
return {
|
|
97
|
+
succeed() {
|
|
98
|
+
return this;
|
|
99
|
+
},
|
|
100
|
+
fail() {
|
|
101
|
+
return this;
|
|
102
|
+
},
|
|
103
|
+
start() {
|
|
104
|
+
return this;
|
|
105
|
+
},
|
|
106
|
+
text: "",
|
|
107
|
+
isSpinning: false
|
|
108
|
+
};
|
|
109
|
+
}
|
|
110
|
+
return ora__default.default(text);
|
|
111
|
+
},
|
|
112
|
+
progressBar(totalSize, text) {
|
|
113
|
+
if (silent) {
|
|
114
|
+
return {
|
|
115
|
+
start() {
|
|
116
|
+
return this;
|
|
117
|
+
},
|
|
118
|
+
stop() {
|
|
119
|
+
return this;
|
|
120
|
+
},
|
|
121
|
+
update() {
|
|
122
|
+
return this;
|
|
123
|
+
}
|
|
124
|
+
};
|
|
125
|
+
}
|
|
126
|
+
const progressBar = new cliProgress__namespace.SingleBar({
|
|
127
|
+
format: `${text ? `${text} |` : ""}${chalk__default.default.green("{bar}")}| {percentage}%`,
|
|
128
|
+
barCompleteChar: "█",
|
|
129
|
+
barIncompleteChar: "░",
|
|
130
|
+
hideCursor: true,
|
|
131
|
+
forceRedraw: true
|
|
132
|
+
});
|
|
133
|
+
progressBar.start(totalSize, 0);
|
|
134
|
+
return progressBar;
|
|
135
|
+
}
|
|
136
|
+
};
|
|
137
|
+
};
|
|
138
|
+
function buildStrapiCloudCommand(argv = process.argv, command = new commander.Command()) {
|
|
139
|
+
const cloudCommands = {
|
|
140
|
+
loginCommand: index_ts.cli.login.command,
|
|
141
|
+
logoutCommand: index_ts.cli.logout.command,
|
|
142
|
+
deployCommand: index_ts.cli.deployProject.command
|
|
143
|
+
};
|
|
144
|
+
command.storeOptionsAsProperties(false).allowUnknownOption(true);
|
|
145
|
+
command.helpOption("-h, --help", "Display help for command");
|
|
146
|
+
command.addHelpCommand("help [command]", "Display help for command");
|
|
147
|
+
command.option("-d, --debug", "Output extra debugging");
|
|
148
|
+
command.option("-s, --silent", "Output less information");
|
|
149
|
+
const cwd = process.cwd();
|
|
150
|
+
const hasDebug = argv.includes("--debug");
|
|
151
|
+
const hasSilent = argv.includes("--silent");
|
|
152
|
+
const logger = createLogger({ debug: hasDebug, silent: hasSilent, timestamp: false });
|
|
153
|
+
const ctx = {
|
|
154
|
+
cwd,
|
|
155
|
+
logger
|
|
156
|
+
};
|
|
157
|
+
const keys = Object.keys(cloudCommands);
|
|
158
|
+
keys.forEach((name) => {
|
|
159
|
+
try {
|
|
160
|
+
cloudCommands[name]({ command, argv, ctx });
|
|
161
|
+
} catch (e) {
|
|
162
|
+
console.error(`Failed to load command ${name}`, e);
|
|
163
|
+
}
|
|
164
|
+
});
|
|
165
|
+
}
|
|
166
|
+
function runStrapiCloudCommand(argv = process.argv, command = new commander.Command()) {
|
|
167
|
+
buildStrapiCloudCommand(argv, command);
|
|
168
|
+
command.parse(argv);
|
|
169
|
+
}
|
|
170
|
+
exports.buildStrapiCloudCommand = buildStrapiCloudCommand;
|
|
171
|
+
exports.runStrapiCloudCommand = runStrapiCloudCommand;
|
|
172
|
+
//# sourceMappingURL=bin.js.map
|
package/dist/bin.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bin.js","sources":["../src/services/logger.ts","../src/bin.ts"],"sourcesContent":["import chalk from 'chalk';\nimport ora from 'ora';\nimport * as cliProgress from 'cli-progress';\n\nexport interface LoggerOptions {\n silent?: boolean;\n debug?: boolean;\n timestamp?: boolean;\n}\n\nexport interface Logger {\n warnings: number;\n errors: number;\n debug: (...args: unknown[]) => void;\n info: (...args: unknown[]) => void;\n success: (...args: unknown[]) => void;\n warn: (...args: unknown[]) => void;\n error: (...args: unknown[]) => void;\n log: (...args: unknown[]) => void;\n spinner: (text: string) => Pick<ora.Ora, 'succeed' | 'fail' | 'start' | 'text' | 'isSpinning'>;\n progressBar: (\n totalSize: number,\n text: string\n ) => Pick<cliProgress.SingleBar, 'start' | 'stop' | 'update'>;\n}\n\nconst createLogger = (options: LoggerOptions = {}): Logger => {\n const { silent = false, debug = false, timestamp = true } = options;\n\n const state = { errors: 0, warning: 0 };\n\n return {\n get warnings() {\n return state.warning;\n },\n\n get errors() {\n return state.errors;\n },\n\n debug(...args) {\n if (silent || !debug) {\n return;\n }\n\n console.log(\n chalk.cyan(`[DEBUG]${timestamp ? `\\t[${new Date().toISOString()}]` : ''}`),\n ...args\n );\n },\n\n info(...args) {\n if (silent) {\n return;\n }\n\n console.info(\n chalk.blue(`[INFO]${timestamp ? `\\t[${new Date().toISOString()}]` : ''}`),\n ...args\n );\n },\n\n log(...args) {\n if (silent) {\n return;\n }\n\n console.info(chalk.blue(`${timestamp ? `\\t[${new Date().toISOString()}]` : ''}`), ...args);\n },\n\n success(...args) {\n if (silent) {\n return;\n }\n\n console.info(\n chalk.green(`[SUCCESS]${timestamp ? `\\t[${new Date().toISOString()}]` : ''}`),\n ...args\n );\n },\n\n warn(...args) {\n state.warning += 1;\n\n if (silent) {\n return;\n }\n\n console.warn(\n chalk.yellow(`[WARN]${timestamp ? `\\t[${new Date().toISOString()}]` : ''}`),\n ...args\n );\n },\n\n error(...args) {\n state.errors += 1;\n\n if (silent) {\n return;\n }\n\n console.error(\n chalk.red(`[ERROR]${timestamp ? `\\t[${new Date().toISOString()}]` : ''}`),\n ...args\n );\n },\n\n // @ts-expect-error – returning a subpart of ora is fine because the types tell us what is what.\n spinner(text: string) {\n if (silent) {\n return {\n succeed() {\n return this;\n },\n fail() {\n return this;\n },\n start() {\n return this;\n },\n text: '',\n isSpinning: false,\n };\n }\n\n return ora(text);\n },\n\n progressBar(totalSize: number, text: string) {\n if (silent) {\n return {\n start() {\n return this;\n },\n stop() {\n return this;\n },\n update() {\n return this;\n },\n };\n }\n\n const progressBar = new cliProgress.SingleBar({\n format: `${text ? `${text} |` : ''}${chalk.green('{bar}')}| {percentage}%`,\n barCompleteChar: '\\u2588',\n barIncompleteChar: '\\u2591',\n hideCursor: true,\n forceRedraw: true,\n });\n\n progressBar.start(totalSize, 0);\n\n return progressBar;\n },\n };\n};\n\nexport { createLogger };\n","import { Command } from 'commander';\nimport { createLogger } from './services/logger';\nimport { CLIContext } from './types';\nimport { cli } from './index';\n\nfunction buildStrapiCloudCommand(argv = process.argv, command = new Command()) {\n const cloudCommands = {\n loginCommand: cli.login.command,\n logoutCommand: cli.logout.command,\n deployCommand: cli.deployProject.command,\n } as const;\n\n // Initial program setup\n command.storeOptionsAsProperties(false).allowUnknownOption(true);\n\n // Help command\n command.helpOption('-h, --help', 'Display help for command');\n command.addHelpCommand('help [command]', 'Display help for command');\n\n // Debug and silent options\n command.option('-d, --debug', 'Output extra debugging');\n command.option('-s, --silent', 'Output less information');\n\n const cwd = process.cwd();\n\n const hasDebug = argv.includes('--debug');\n const hasSilent = argv.includes('--silent');\n\n const logger = createLogger({ debug: hasDebug, silent: hasSilent, timestamp: false });\n\n const ctx = {\n cwd,\n logger,\n } satisfies CLIContext;\n\n const keys = Object.keys(cloudCommands) as (keyof typeof cloudCommands)[];\n\n // Load all commands\n keys.forEach((name) => {\n try {\n // Add this command to the Commander command object\n cloudCommands[name]({ command, argv, ctx });\n } catch (e) {\n console.error(`Failed to load command ${name}`, e);\n }\n });\n}\n\nfunction runStrapiCloudCommand(argv = process.argv, command = new Command()) {\n buildStrapiCloudCommand(argv, command);\n command.parse(argv);\n}\n\nexport { buildStrapiCloudCommand, runStrapiCloudCommand };\n"],"names":["chalk","ora","cliProgress","Command","cli"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0BA,MAAM,eAAe,CAAC,UAAyB,OAAe;AAC5D,QAAM,EAAE,SAAS,OAAO,QAAQ,OAAO,YAAY,KAAS,IAAA;AAE5D,QAAM,QAAQ,EAAE,QAAQ,GAAG,SAAS,EAAE;AAE/B,SAAA;AAAA,IACL,IAAI,WAAW;AACb,aAAO,MAAM;AAAA,IACf;AAAA,IAEA,IAAI,SAAS;AACX,aAAO,MAAM;AAAA,IACf;AAAA,IAEA,SAAS,MAAM;AACT,UAAA,UAAU,CAAC,OAAO;AACpB;AAAA,MACF;AAEQ,cAAA;AAAA,QACNA,eAAAA,QAAM,KAAK,UAAU,YAAY,MAAM,oBAAI,KAAK,GAAE,YAAa,CAAA,MAAM,EAAE,EAAE;AAAA,QACzE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AW,WAAW,MAAA,CAAO;AAEpF,QAAM,MAAM;AAAA,IACV;AAAA,IACA;AAAA,EAAA;AAGI,QAAA,OAAO,OAAO,KAAK,aAAa;AAGjC,OAAA,QAAQ,CAAC,SAAS;AACjB,QAAA;AAEF,oBAAc,IAAI,EAAE,EAAE,SAAS,MAAM,KAAK;AAAA,aACnC,GAAG;AACV,cAAQ,MAAM,0BAA0B,IAAI,IAAI,CAAC;AAAA,IACnD;AAAA,EAAA,CACD;AACH;AAEA,SAAS,sBAAsB,OAAO,QAAQ,MAAM,UAAU,IAAID,UAAAA,WAAW;AAC3E,0BAAwB,MAAM,OAAO;AACrC,UAAQ,MAAM,IAAI;AACpB;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../../src/config/api.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,SAAS;;CAErB,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export declare const CONFIG_FILENAME = "config.json";
|
|
2
|
+
export type LocalConfig = {
|
|
3
|
+
token?: string;
|
|
4
|
+
};
|
|
5
|
+
export declare function getTmpStoragePath(): string;
|
|
6
|
+
export declare function getLocalConfig(): LocalConfig;
|
|
7
|
+
export declare function saveLocalConfig(data: LocalConfig): void;
|
|
8
|
+
//# sourceMappingURL=local.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"local.d.ts","sourceRoot":"","sources":["../../src/config/local.ts"],"names":[],"mappings":"AAOA,eAAO,MAAM,eAAe,gBAAgB,CAAC;AAE7C,MAAM,MAAM,WAAW,GAAG;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AAWF,wBAAgB,iBAAiB,WAMhC;AAaD,wBAAgB,cAAc,IAAI,WAAW,CAW5C;AAED,wBAAgB,eAAe,CAAC,IAAI,EAAE,WAAW,QAIhD"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"action.d.ts","sourceRoot":"","sources":["../../src/create-project/action.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,UAAU,EAAgC,MAAM,UAAU,CAAC;8BAgCpD,UAAU;AAA/B,wBAyBE"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import action from './action';
|
|
2
|
+
export { action };
|
|
3
|
+
declare const _default: {
|
|
4
|
+
name: string;
|
|
5
|
+
description: string;
|
|
6
|
+
action: (ctx: import("..").CLIContext) => () => Promise<import("..").ProjectInfos | undefined>;
|
|
7
|
+
};
|
|
8
|
+
export default _default;
|
|
9
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/create-project/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,UAAU,CAAC;AAE9B,OAAO,EAAE,MAAM,EAAE,CAAC;;;;;;AAElB,wBAIE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"action.d.ts","sourceRoot":"","sources":["../../src/deploy-project/action.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,UAAU,EAAgB,MAAM,UAAU,CAAC;8BAwH9B,UAAU;AAArC,wBA6BE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"command.d.ts","sourceRoot":"","sources":["../../src/deploy-project/command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,kBAAkB,EAAE,MAAM,UAAU,CAAC;AAInD;;GAEG;AACH,QAAA,MAAM,OAAO,EAAE,kBAMd,CAAC;AAEF,eAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import action from './action';
|
|
2
|
+
import command from './command';
|
|
3
|
+
export { action, command };
|
|
4
|
+
declare const _default: {
|
|
5
|
+
name: string;
|
|
6
|
+
description: string;
|
|
7
|
+
action: (ctx: import("..").CLIContext) => Promise<void>;
|
|
8
|
+
command: import("..").StrapiCloudCommand;
|
|
9
|
+
};
|
|
10
|
+
export default _default;
|
|
11
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/deploy-project/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,UAAU,CAAC;AAC9B,OAAO,OAAO,MAAM,WAAW,CAAC;AAEhC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC;;;;;;;AAE3B,wBAKE"}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as deployProject from './deploy-project';
|
|
2
|
+
import * as login from './login';
|
|
3
|
+
import * as logout from './logout';
|
|
4
|
+
import * as createProject from './create-project';
|
|
5
|
+
export declare const cli: {
|
|
6
|
+
deployProject: typeof deployProject;
|
|
7
|
+
login: typeof login;
|
|
8
|
+
logout: typeof logout;
|
|
9
|
+
createProject: typeof createProject;
|
|
10
|
+
};
|
|
11
|
+
export * as services from './services';
|
|
12
|
+
export * from './types';
|
|
13
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,aAAa,MAAM,kBAAkB,CAAC;AAClD,OAAO,KAAK,KAAK,MAAM,SAAS,CAAC;AACjC,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,KAAK,aAAa,MAAM,kBAAkB,CAAC;AAElD,eAAO,MAAM,GAAG;;;;;CAKf,CAAC;AAEF,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAC;AAEvC,cAAc,SAAS,CAAC"}
|