@embeddable.com/sdk-core 3.2.0-next.2 → 3.2.0-next.4

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.
@@ -1,9 +1,9 @@
1
1
  export type EmbeddableConfig = {
2
2
  plugins: (() => {
3
3
  pluginName: string;
4
- build: (config: EmbeddableConfig) => Promise<void>;
5
- cleanup: (config: EmbeddableConfig) => Promise<void>;
6
- validate: (config: EmbeddableConfig) => Promise<void>;
4
+ build: (config: EmbeddableConfig) => Promise<unknown>;
5
+ cleanup: (config: EmbeddableConfig) => Promise<unknown>;
6
+ validate: (config: EmbeddableConfig) => Promise<unknown>;
7
7
  })[];
8
8
  pushBaseUrl?: string;
9
9
  audienceUrl?: string;
@@ -42,9 +42,9 @@ declare const _default: ({ plugins, pushBaseUrl, audienceUrl, authDomain, authCl
42
42
  rollbarAccessToken: string;
43
43
  plugins: (() => {
44
44
  pluginName: string;
45
- build: (config: EmbeddableConfig) => Promise<void>;
46
- cleanup: (config: EmbeddableConfig) => Promise<void>;
47
- validate: (config: EmbeddableConfig) => Promise<void>;
45
+ build: (config: EmbeddableConfig) => Promise<unknown>;
46
+ cleanup: (config: EmbeddableConfig) => Promise<unknown>;
47
+ validate: (config: EmbeddableConfig) => Promise<unknown>;
48
48
  })[];
49
49
  };
50
50
  export default _default;
package/lib/index.esm.js CHANGED
@@ -20082,6 +20082,8 @@ const inquirerSelect = import('@inquirer/select');
20082
20082
  const YAML_OR_JS_FILES = /^(.*)\.(cube|sc)\.(ya?ml|js)$/;
20083
20083
  let ora$1;
20084
20084
  var push = async () => {
20085
+ var _a;
20086
+ let spinnerPushing;
20085
20087
  try {
20086
20088
  checkNodeVersion();
20087
20089
  ora$1 = (await oraP$1).default;
@@ -20092,14 +20094,15 @@ var push = async () => {
20092
20094
  const filesList = await findFiles(config.client.srcDir, YAML_OR_JS_FILES);
20093
20095
  await archive(config, filesList);
20094
20096
  spinnerArchive.succeed("Bundling completed");
20095
- const spinnerPushing = ora$1(`Publishing to ${workspaceName} using ${config.pushBaseUrl}...`).start();
20097
+ spinnerPushing = ora$1(`Publishing to ${workspaceName} using ${config.pushBaseUrl}...`).start();
20096
20098
  await sendBuild(config, { workspaceId, token });
20097
20099
  spinnerPushing.succeed(`Published to ${workspaceName} using ${config.pushBaseUrl}`);
20098
20100
  }
20099
20101
  catch (error) {
20100
- console.log(error);
20102
+ spinnerPushing === null || spinnerPushing === void 0 ? void 0 : spinnerPushing.fail("Publishing failed");
20103
+ console.error(((_a = error.response) === null || _a === void 0 ? void 0 : _a.data) || (error === null || error === void 0 ? void 0 : error.message) || error);
20101
20104
  await reportErrorToRollbar(error);
20102
- throw error;
20105
+ process.exit(1);
20103
20106
  }
20104
20107
  };
20105
20108
  async function selectWorkspace(ctx, token) {