@lark-apaas/fullstack-cli 1.1.28-alpha.20 → 1.1.28-alpha.21
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/dist/index.js +11 -5
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -7255,6 +7255,12 @@ var SCENE_CONFIGS = {
|
|
|
7255
7255
|
buildRequestBody: () => ({ commitID: "" })
|
|
7256
7256
|
}
|
|
7257
7257
|
};
|
|
7258
|
+
var UPLOAD_STATIC_DEFAULTS = {
|
|
7259
|
+
staticDir: "shared/static",
|
|
7260
|
+
tosutilPath: "tosutil",
|
|
7261
|
+
endpoint: "tos-cn-beijing.volces.com",
|
|
7262
|
+
region: "cn-beijing"
|
|
7263
|
+
};
|
|
7258
7264
|
|
|
7259
7265
|
// src/commands/build/api-client.ts
|
|
7260
7266
|
async function genArtifactUploadCredential(appId, body) {
|
|
@@ -7363,10 +7369,10 @@ async function uploadStatic(options) {
|
|
|
7363
7369
|
try {
|
|
7364
7370
|
const {
|
|
7365
7371
|
appId,
|
|
7366
|
-
staticDir =
|
|
7367
|
-
tosutilPath =
|
|
7368
|
-
endpoint =
|
|
7369
|
-
region =
|
|
7372
|
+
staticDir = UPLOAD_STATIC_DEFAULTS.staticDir,
|
|
7373
|
+
tosutilPath = UPLOAD_STATIC_DEFAULTS.tosutilPath,
|
|
7374
|
+
endpoint = UPLOAD_STATIC_DEFAULTS.endpoint,
|
|
7375
|
+
region = UPLOAD_STATIC_DEFAULTS.region
|
|
7370
7376
|
} = options;
|
|
7371
7377
|
const resolvedStaticDir = path21.resolve(staticDir);
|
|
7372
7378
|
if (!fs25.existsSync(resolvedStaticDir)) {
|
|
@@ -7532,7 +7538,7 @@ var uploadStaticCommand = {
|
|
|
7532
7538
|
name: "upload-static",
|
|
7533
7539
|
description: "Upload shared/static files to TOS",
|
|
7534
7540
|
register(program) {
|
|
7535
|
-
program.command(this.name).description(this.description).requiredOption("--app-id <id>", "Application ID").option("--static-dir <dir>", "Static files directory",
|
|
7541
|
+
program.command(this.name).description(this.description).requiredOption("--app-id <id>", "Application ID").option("--static-dir <dir>", "Static files directory", UPLOAD_STATIC_DEFAULTS.staticDir).option("--tosutil-path <path>", "Path to tosutil binary", UPLOAD_STATIC_DEFAULTS.tosutilPath).option("--endpoint <endpoint>", "TOS endpoint", UPLOAD_STATIC_DEFAULTS.endpoint).option("--region <region>", "TOS region", UPLOAD_STATIC_DEFAULTS.region).action(async (options) => {
|
|
7536
7542
|
await uploadStatic(options);
|
|
7537
7543
|
});
|
|
7538
7544
|
}
|