vite-plugin-zephyr 0.0.12 → 0.0.14

Sign up to get free protection for your applications and to get access to all the features.
Files changed (34) hide show
  1. package/LICENSE +39 -0
  2. package/README.md +0 -9
  3. package/dist/index.js.map +1 -0
  4. package/{src → dist}/lib/load_extra_files_from_dist.d.ts +1 -0
  5. package/{src → dist}/lib/load_extra_files_from_dist.js +1 -1
  6. package/dist/lib/load_extra_files_from_dist.js.map +1 -0
  7. package/{src → dist}/lib/load_public_dir.js +1 -1
  8. package/dist/lib/load_public_dir.js.map +1 -0
  9. package/{src → dist}/lib/load_static_entries.d.ts +1 -0
  10. package/{src → dist}/lib/load_static_entries.js +1 -1
  11. package/dist/lib/load_static_entries.js.map +1 -0
  12. package/{src → dist}/lib/vite-plugin-zephyr-partial.js +34 -30
  13. package/dist/lib/vite-plugin-zephyr-partial.js.map +1 -0
  14. package/dist/lib/vite-plugin-zephyr.d.ts +2 -0
  15. package/dist/lib/vite-plugin-zephyr.js +146 -0
  16. package/dist/lib/vite-plugin-zephyr.js.map +1 -0
  17. package/dist/lib/zephyr-internal-options.js.map +1 -0
  18. package/dist/package.json +21 -0
  19. package/package.json +10 -7
  20. package/src/index.js.map +0 -1
  21. package/src/lib/load_extra_files_from_dist.js.map +0 -1
  22. package/src/lib/load_public_dir.js.map +0 -1
  23. package/src/lib/load_static_entries.js.map +0 -1
  24. package/src/lib/vite-plugin-zephyr-partial.js.map +0 -1
  25. package/src/lib/vite-plugin-zephyr.d.ts +0 -9
  26. package/src/lib/vite-plugin-zephyr.js +0 -212
  27. package/src/lib/vite-plugin-zephyr.js.map +0 -1
  28. package/src/lib/zephyr-internal-options.js.map +0 -1
  29. /package/{src → dist}/index.d.ts +0 -0
  30. /package/{src → dist}/index.js +0 -0
  31. /package/{src → dist}/lib/load_public_dir.d.ts +0 -0
  32. /package/{src → dist}/lib/vite-plugin-zephyr-partial.d.ts +0 -0
  33. /package/{src → dist}/lib/zephyr-internal-options.d.ts +0 -0
  34. /package/{src → dist}/lib/zephyr-internal-options.js +0 -0
package/LICENSE ADDED
@@ -0,0 +1,39 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ ...
13
+
14
+ END OF TERMS AND CONDITIONS
15
+
16
+ APPENDIX: How to apply the Apache License to your work.
17
+
18
+ To apply the Apache License to your work, attach the following
19
+ boilerplate notice, with the fields enclosed by brackets "[]"
20
+ replaced with your own identifying information. (Don't include
21
+ the brackets!) The text should be enclosed in the appropriate
22
+ comment syntax for the file format. We also recommend that a
23
+ file or class name and description of purpose be included on the
24
+ same line as the copyright notice for each file. The "copyright"
25
+ word should be left as is (without quotes).
26
+
27
+ Copyright [2023] [Zephyr Cloud]
28
+
29
+ Licensed under the Apache License, Version 2.0 (the "License");
30
+ you may not use this file except in compliance with the License.
31
+ You may obtain a copy of the License at
32
+
33
+ http://www.apache.org/licenses/LICENSE-2.0
34
+
35
+ Unless required by applicable law or agreed to in writing, software
36
+ distributed under the License is distributed on an "AS IS" BASIS,
37
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
38
+ See the License for the specific language governing permissions and
39
+ limitations under the License.
package/README.md CHANGED
@@ -1,11 +1,2 @@
1
1
  # vite-plugin-zephyr
2
2
 
3
- This library was generated with [Nx](https://nx.dev).
4
-
5
- ## Building
6
-
7
- Run `nx build vite-plugin-zephyr` to build the library.
8
-
9
- ## Running unit tests
10
-
11
- Run `nx test vite-plugin-zephyr` to execute the unit tests via [Jest](https://jestjs.io).
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAAA,+DAAsD;AAA7C,gHAAA,UAAU,OAAA;AACnB,+EAAqE;AAA5D,+HAAA,iBAAiB,OAAA"}
@@ -2,6 +2,7 @@ import { OutputAsset, OutputBundle } from 'rollup';
2
2
  interface LoadExtraFilesFromDistOptions {
3
3
  root: string;
4
4
  bundle: OutputBundle;
5
+ outDir: string;
5
6
  }
6
7
  export declare function load_extra_files_from_dist(props: LoadExtraFilesFromDistOptions): Promise<OutputAsset[]>;
7
8
  export {};
@@ -10,7 +10,7 @@ function load_extra_files_from_dist(props) {
10
10
  return tslib_1.__awaiter(this, void 0, void 0, function* () {
11
11
  const { root, bundle } = props;
12
12
  const publicAssets = [];
13
- const root_dist_dir = (0, node_path_1.resolve)(root, 'dist');
13
+ const root_dist_dir = (0, node_path_1.resolve)(root, props.outDir);
14
14
  const loadDir = (destDir) => tslib_1.__awaiter(this, void 0, void 0, function* () {
15
15
  for (const file of (0, node_fs_1.readdirSync)(destDir)) {
16
16
  const destFile = (0, node_path_1.resolve)(destDir, file);
@@ -0,0 +1 @@
1
+ {"version":3,"file":"load_extra_files_from_dist.js","sourceRoot":"","sources":["../../src/lib/load_extra_files_from_dist.ts"],"names":[],"mappings":";;;;AACA,yCAA8C;AAC9C,qCAA0D;AAC1D,+BAAqC;AACrC,yCAAsC;AAQtC,SAAsB,0BAA0B,CAC9C,KAAoC;;QAEpC,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,KAAK,CAAC;QAC/B,MAAM,YAAY,GAAkB,EAAE,CAAC;QAEvC,MAAM,aAAa,GAAG,IAAA,mBAAO,EAAC,IAAI,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;QAClD,MAAM,OAAO,GAAG,CAAO,OAAe,EAAE,EAAE;YACxC,KAAK,MAAM,IAAI,IAAI,IAAA,qBAAW,EAAC,OAAO,CAAC,EAAE,CAAC;gBACxC,MAAM,QAAQ,GAAG,IAAA,mBAAO,EAAC,OAAO,EAAE,IAAI,CAAC,CAAC;gBACxC,MAAM,IAAI,GAAG,IAAA,kBAAQ,EAAC,QAAQ,CAAC,CAAC;gBAChC,IAAI,IAAI,CAAC,WAAW,EAAE,EAAE,CAAC;oBACvB,MAAM,OAAO,CAAC,QAAQ,CAAC,CAAC;oBACxB,SAAS;gBACX,CAAC;gBACD,MAAM,QAAQ,GAAG,IAAA,oBAAa,EAAC,IAAA,oBAAQ,EAAC,aAAa,EAAE,QAAQ,CAAC,CAAC,CAAC;gBAClE,IAAI,CAAC,CAAC,QAAQ,IAAI,MAAM,CAAC,EAAE,CAAC;oBAC1B,YAAY,CAAC,IAAI,CAAC;wBAChB,QAAQ;wBACR,IAAI,EAAE,IAAI;wBACV,kBAAkB,EAAE,KAAK;wBACzB,MAAM,EAAE,MAAM,IAAA,qBAAS,EAAC,kBAAQ,CAAC,CAAC,QAAQ,CAAC;wBAC3C,IAAI,EAAE,OAAO;qBACd,CAAC,CAAC;gBACL,CAAC;YACH,CAAC;QACH,CAAC,CAAA,CAAC;QACF,MAAM,OAAO,CAAC,aAAa,CAAC,CAAC;QAE7B,OAAO,YAAY,CAAC;IACtB,CAAC;CAAA;AA9BD,gEA8BC"}
@@ -19,7 +19,7 @@ function load_public_dir(props) {
19
19
  const destFile = (0, node_path_1.resolve)(destDir, file);
20
20
  const stat = (0, node_fs_1.statSync)(srcFile);
21
21
  if (stat.isDirectory()) {
22
- loadDir(srcFile, destFile);
22
+ yield loadDir(srcFile, destFile);
23
23
  }
24
24
  else {
25
25
  publicAssets.push({
@@ -0,0 +1 @@
1
+ {"version":3,"file":"load_public_dir.js","sourceRoot":"","sources":["../../src/lib/load_public_dir.ts"],"names":[],"mappings":";;;;AACA,qCAA0D;AAC1D,yCAAwD;AACxD,+BAAqC;AACrC,yCAAsC;AAOtC,SAAsB,eAAe,CACnC,KAA2B;;QAE3B,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,GAAG,KAAK,CAAC;QACpC,MAAM,YAAY,GAAkB,EAAE,CAAC;QAEvC,MAAM,OAAO,GAAG,CAAO,MAAc,EAAE,OAAe,EAAE,EAAE;YACxD,KAAK,MAAM,IAAI,IAAI,IAAA,qBAAW,EAAC,MAAM,CAAC,EAAE,CAAC;gBACvC,MAAM,OAAO,GAAG,IAAA,mBAAO,EAAC,MAAM,EAAE,IAAI,CAAC,CAAC;gBACtC,IAAI,OAAO,KAAK,OAAO,EAAE,CAAC;oBACxB,SAAS;gBACX,CAAC;gBACD,MAAM,QAAQ,GAAG,IAAA,mBAAO,EAAC,OAAO,EAAE,IAAI,CAAC,CAAC;gBACxC,MAAM,IAAI,GAAG,IAAA,kBAAQ,EAAC,OAAO,CAAC,CAAC;gBAC/B,IAAI,IAAI,CAAC,WAAW,EAAE,EAAE,CAAC;oBACvB,MAAM,OAAO,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC;gBACnC,CAAC;qBAAM,CAAC;oBACN,YAAY,CAAC,IAAI,CAAC;wBAChB,QAAQ,EAAE,IAAA,oBAAa,EAAC,IAAA,oBAAQ,EAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;wBACnD,IAAI,EAAE,IAAA,oBAAQ,EAAC,IAAI,CAAC;wBACpB,kBAAkB,EAAE,KAAK;wBACzB,MAAM,EAAE,MAAM,IAAA,qBAAS,EAAC,kBAAQ,CAAC,CAAC,OAAO,CAAC;wBAC1C,IAAI,EAAE,OAAO;qBACd,CAAC,CAAC;gBACL,CAAC;YACH,CAAC;QACH,CAAC,CAAA,CAAC;QACF,MAAM,OAAO,CAAC,SAAS,EAAE,MAAM,CAAC,CAAC;QACjC,OAAO,YAAY,CAAC;IACtB,CAAC;CAAA;AA7BD,0CA6BC"}
@@ -2,6 +2,7 @@ import { OutputAsset, OutputBundle } from 'rollup';
2
2
  interface LoadStaticEntriesOptions {
3
3
  root: string;
4
4
  bundle: OutputBundle;
5
+ outDir: string;
5
6
  }
6
7
  export declare function load_static_entries(props: LoadStaticEntriesOptions): Promise<OutputAsset[]>;
7
8
  export {};
@@ -15,7 +15,7 @@ function load_static_entries(props) {
15
15
  return tslib_1.__awaiter(this, void 0, void 0, function* () {
16
16
  const { root, bundle } = props;
17
17
  const publicAssets = [];
18
- const root_dist_dir = (0, node_path_1.resolve)(root, 'dist');
18
+ const root_dist_dir = (0, node_path_1.resolve)(root, props.outDir);
19
19
  const loadDir = (destDir) => tslib_1.__awaiter(this, void 0, void 0, function* () {
20
20
  for (const file of (0, node_fs_1.readdirSync)(destDir)) {
21
21
  const destFile = (0, node_path_1.resolve)(destDir, file);
@@ -0,0 +1 @@
1
+ {"version":3,"file":"load_static_entries.js","sourceRoot":"","sources":["../../src/lib/load_static_entries.ts"],"names":[],"mappings":";;;;AACA,yCAA8C;AAC9C,qCAA0D;AAC1D,+BAAqC;AACrC,yCAAsC;AAQtC,MAAM,aAAa,GAA4B;IAC7C,YAAY,EAAE,IAAI;IAClB,UAAU,EAAE,IAAI;IAChB,aAAa,EAAE,IAAI;CACpB,CAAC;AAEF,SAAsB,mBAAmB,CACvC,KAA+B;;QAE/B,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,KAAK,CAAC;QAC/B,MAAM,YAAY,GAAkB,EAAE,CAAC;QAEvC,MAAM,aAAa,GAAG,IAAA,mBAAO,EAAC,IAAI,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;QAElD,MAAM,OAAO,GAAG,CAAO,OAAe,EAAE,EAAE;YACxC,KAAK,MAAM,IAAI,IAAI,IAAA,qBAAW,EAAC,OAAO,CAAC,EAAE,CAAC;gBACxC,MAAM,QAAQ,GAAG,IAAA,mBAAO,EAAC,OAAO,EAAE,IAAI,CAAC,CAAC;gBACxC,MAAM,IAAI,GAAG,IAAA,kBAAQ,EAAC,QAAQ,CAAC,CAAC;gBAChC,IAAI,IAAI,CAAC,WAAW,EAAE,EAAE,CAAC;oBACvB,MAAM,OAAO,CAAC,QAAQ,CAAC,CAAC;oBACxB,SAAS;gBACX,CAAC;gBACD,MAAM,QAAQ,GAAG,IAAA,oBAAa,EAAC,IAAA,oBAAQ,EAAC,aAAa,EAAE,QAAQ,CAAC,CAAC,CAAC;gBAClE,IAAI,aAAa,CAAC,IAAI,CAAC,EAAE,CAAC;oBACxB,YAAY,CAAC,IAAI,CAAC;wBAChB,QAAQ;wBACR,IAAI,EAAE,IAAI;wBACV,kBAAkB,EAAE,KAAK;wBACzB,MAAM,EAAE,MAAM,IAAA,qBAAS,EAAC,kBAAQ,CAAC,CAAC,QAAQ,CAAC;wBAC3C,IAAI,EAAE,OAAO;qBACd,CAAC,CAAC;gBACL,CAAC;YACH,CAAC;QACH,CAAC,CAAA,CAAC;QACF,MAAM,OAAO,CAAC,aAAa,CAAC,CAAC;QAC7B,OAAO,YAAY,CAAC;IACtB,CAAC;CAAA;AA9BD,kDA8BC"}
@@ -37,6 +37,7 @@ function withZephyrPartial() {
37
37
  }
38
38
  const _extra_assets = yield (0, load_extra_files_from_dist_1.load_extra_files_from_dist)({
39
39
  root: vite_internal_options.root,
40
+ outDir: vite_internal_options.outDir,
40
41
  bundle,
41
42
  });
42
43
  publicAssets.push(..._extra_assets);
@@ -51,41 +52,42 @@ function _zephyr_partial(options) {
51
52
  var _a;
52
53
  const { assets, vite_internal_options } = options;
53
54
  const path_to_execution_dir = vite_internal_options.root;
54
- (0, zephyr_edge_contract_1.ze_log)('Configuring with Zephyr');
55
- const packageJson = (0, zephyr_agent_1.getPackageJson)(path_to_execution_dir);
55
+ (0, zephyr_edge_contract_1.ze_log)('Configuring with Zephyr...');
56
+ const packageJson = yield (0, zephyr_agent_1.getPackageJson)(path_to_execution_dir);
56
57
  (0, zephyr_edge_contract_1.ze_log)('Loaded Package JSON', packageJson);
57
58
  if (!packageJson)
58
- return (0, zephyr_edge_contract_1.ze_error)('Could not find package json');
59
- const gitInfo = (0, zephyr_agent_1.getGitInfo)();
59
+ return (0, zephyr_edge_contract_1.ze_error)("BU10010", 'package.json not found.');
60
+ const gitInfo = yield (0, zephyr_agent_1.getGitInfo)();
60
61
  (0, zephyr_edge_contract_1.ze_log)('Loaded Git Info', gitInfo);
61
- if (!gitInfo ||
62
- !(gitInfo === null || gitInfo === void 0 ? void 0 : gitInfo.app.org) ||
63
- !(gitInfo === null || gitInfo === void 0 ? void 0 : gitInfo.app.project) ||
64
- !(packageJson === null || packageJson === void 0 ? void 0 : packageJson.name))
65
- return (0, zephyr_edge_contract_1.ze_error)('Could not get git info');
66
- const application_uid = (0, zephyr_edge_contract_1.createFullAppName)({
62
+ if (!gitInfo || !(gitInfo === null || gitInfo === void 0 ? void 0 : gitInfo.app.org) ||
63
+ !(gitInfo === null || gitInfo === void 0 ? void 0 : gitInfo.app.project))
64
+ return (0, zephyr_edge_contract_1.ze_error)("BU10016", `Could not get git info. Can you confirm the current directory has initialized as a git repository?`);
65
+ if (!(packageJson === null || packageJson === void 0 ? void 0 : packageJson.name))
66
+ return (0, zephyr_edge_contract_1.ze_error)("BU10013", 'package.json must have a name and version.');
67
+ const application_uid = (0, zephyr_edge_contract_1.createApplicationUID)({
67
68
  org: gitInfo.app.org,
68
69
  project: gitInfo.app.project,
69
70
  name: packageJson === null || packageJson === void 0 ? void 0 : packageJson.name,
70
71
  });
71
- (0, zephyr_edge_contract_1.ze_log)('Going to check auth token or get it');
72
+ (0, zephyr_edge_contract_1.ze_log)('Going to check auth token or get it...');
72
73
  yield (0, zephyr_agent_1.checkAuth)();
73
- (0, zephyr_edge_contract_1.ze_log)('Got auth token, going to get application configuration');
74
- const { username, email, EDGE_URL } = yield (0, zephyr_agent_1.getApplicationConfiguration)({
75
- application_uid,
76
- });
77
- (0, zephyr_edge_contract_1.ze_log)('Got application configuration', { username, email, EDGE_URL });
78
- (0, zephyr_edge_contract_1.ze_log)('Going to get build id');
79
- const buildId = yield (0, zephyr_agent_1.getBuildId)(application_uid).catch((err) => {
80
- logEvent({
81
- level: 'error',
82
- action: 'build:get-build-id:error',
83
- message: `error receiving build number for '${email}'\n
74
+ (0, zephyr_edge_contract_1.ze_log)('Got auth token, going to get application configuration and build id...');
75
+ const [appConfig, buildId, hash_set] = yield Promise.all([
76
+ (0, zephyr_agent_1.getApplicationConfiguration)({ application_uid }),
77
+ (0, zephyr_agent_1.getBuildId)(application_uid).catch((err) => {
78
+ logEvent({
79
+ level: 'error',
80
+ action: 'build:get-build-id:error',
81
+ message: `error receiving build number for '${email}'\n
84
82
  ${err.message}\n`,
85
- });
86
- });
83
+ });
84
+ }),
85
+ (0, zephyr_agent_1.get_hash_list)(application_uid),
86
+ ]);
87
+ const { username, email, EDGE_URL } = appConfig;
88
+ (0, zephyr_edge_contract_1.ze_log)('Got application configuration', { username, email, EDGE_URL });
87
89
  if (!buildId)
88
- return (0, zephyr_edge_contract_1.ze_error)('[zephyr]: Could not get build id');
90
+ return (0, zephyr_edge_contract_1.ze_error)("BU10019", 'Could not get build id.');
89
91
  const pluginOptions = {
90
92
  pluginName: 'rollup-plugin-zephyr',
91
93
  application_uid,
@@ -106,7 +108,7 @@ function _zephyr_partial(options) {
106
108
  },
107
109
  mfConfig: void 0,
108
110
  };
109
- (0, zephyr_edge_contract_1.ze_log)('zephyr agent started.');
111
+ (0, zephyr_edge_contract_1.ze_log)('\n--------\n zephyr agent started. \n ------ \n');
110
112
  const logEvent = (0, zephyr_agent_1.logger)(pluginOptions);
111
113
  const zeStart = Date.now();
112
114
  const extractBuffer = (asset) => {
@@ -143,16 +145,18 @@ function _zephyr_partial(options) {
143
145
  username,
144
146
  email,
145
147
  });
146
- const missingAssets = yield (0, zephyr_agent_1.zeUploadSnapshot)(pluginOptions, snapshot).catch((err) => (0, zephyr_edge_contract_1.ze_error)('Failed to upload snapshot.', err));
147
- if (typeof missingAssets === 'undefined')
148
- return (0, zephyr_edge_contract_1.ze_error)('Snapshot upload gave no result, exiting');
148
+ yield (0, zephyr_agent_1.zeUploadSnapshot)(pluginOptions, snapshot).catch((err) => (0, zephyr_edge_contract_1.ze_error)("DE10018", 'Failed to upload snapshot.', err));
149
+ const missingAssets = (0, zephyr_agent_1.get_missing_assets)({ assetsMap, hash_set });
149
150
  const assetsUploadSuccess = yield (0, zephyr_agent_1.zeUploadAssets)(pluginOptions, {
150
151
  missingAssets,
151
152
  assetsMap,
152
153
  count: Object.keys(assets).length,
153
154
  });
154
155
  if (!assetsUploadSuccess)
155
- return (0, zephyr_edge_contract_1.ze_error)('Failed to upload assets.', assetsUploadSuccess);
156
+ return (0, zephyr_edge_contract_1.ze_error)("DE10017", 'Failed to upload assets.', assetsUploadSuccess);
157
+ if (missingAssets.length) {
158
+ yield (0, zephyr_agent_1.update_hash_list)(application_uid, assetsMap);
159
+ }
156
160
  yield (0, zephyr_edge_contract_1.savePartialAssetMap)(application_uid, (_a = vite_internal_options.configFile) !== null && _a !== void 0 ? _a : 'partial', assetsMap);
157
161
  logEvent({
158
162
  level: 'info',
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vite-plugin-zephyr-partial.js","sourceRoot":"","sources":["../../src/lib/vite-plugin-zephyr-partial.ts"],"names":[],"mappings":";;;;AAOA,8BAA8B;AAE9B,+DAM8B;AAC9B,+CAcsB;AAEtB,uDAAoD;AACpD,6EAA0E;AAG1E,SAAgB,iBAAiB;IAC/B,IAAI,MAAM,GAAiB,EAAE,CAAC;IAC9B,MAAM,qBAAqB,GAAG,EAA2B,CAAC;IAE1D,OAAO;QACL,IAAI,EAAE,qBAAqB;QAC3B,KAAK,EAAE,OAAO;QACd,OAAO,EAAE,MAAM;QACf,cAAc,EAAE,CAAO,MAAsB,EAAE,EAAE;YAC/C,MAAM,CAAC,MAAM,CAAC,qBAAqB,EAAE;gBACnC,IAAI,EAAE,MAAM,CAAC,IAAI;gBACjB,UAAU,EAAE,MAAM,CAAC,UAAU;gBAC7B,MAAM,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM;gBAC3B,SAAS,EAAE,MAAM,CAAC,SAAS;aAC5B,CAAC,CAAC;QACL,CAAC,CAAA;QAED,WAAW,EAAE,CACX,OAAgC,EAChC,OAAqB,EACrB,EAAE;YACF,qBAAqB,CAAC,GAAG,GAAG,OAAO,CAAC,GAAG,CAAC;YACxC,MAAM,GAAG,OAAO,CAAC;QACnB,CAAC,CAAA;QAED,WAAW,EAAE,GAAS,EAAE;YACtB,M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AAQ,EAAC,SAAS,EAAE,4BAA4B,EAAE,GAAG,CAAC,CACvD,CAAC;QAEF,MAAM,aAAa,GAAG,IAAA,iCAAkB,EAAC,EAAE,SAAS,EAAE,QAAQ,EAAE,CAAC,CAAC;QAElE,MAAM,mBAAmB,GAAG,MAAM,IAAA,6BAAc,EAAC,aAAa,EAAE;YAC9D,aAAa;YACb,SAAS;YACT,KAAK,EAAE,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,MAAM;SAClC,CAAC,CAAC;QAEH,IAAI,CAAC,mBAAmB;YACtB,OAAO,IAAA,+BAAQ,EAAC,SAAS,EAAE,0BAA0B,EAAE,mBAAmB,CAAC,CAAC;QAE9E,IAAI,aAAa,CAAC,MAAM,EAAE,CAAC;YACzB,MAAM,IAAA,+BAAgB,EAAC,eAAe,EAAE,SAAS,CAAC,CAAC;QACrD,CAAC;QAED,MAAM,IAAA,0CAAmB,EACvB,eAAe,EACf,MAAA,qBAAqB,CAAC,UAAU,mCAAI,SAAS,EAC7C,SAAS,CACV,CAAC;QAEF,QAAQ,CAAC;YACP,KAAK,EAAE,MAAM;YACb,MAAM,EAAE,mBAAmB;YAC3B,OAAO,EAAE,qBAAqB,IAAI,CAAC,GAAG,EAAE,GAAG,OAAO,IAAI;SACvD,CAAC,CAAC;IACL,CAAC;CAAA"}
@@ -0,0 +1,2 @@
1
+ import { Plugin } from 'vite';
2
+ export declare function withZephyr(): Plugin;
@@ -0,0 +1,146 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.withZephyr = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const isCI = require("is-ci");
6
+ const zephyr_edge_contract_1 = require("zephyr-edge-contract");
7
+ const zephyr_agent_1 = require("zephyr-agent");
8
+ const load_static_entries_1 = require("./load_static_entries");
9
+ const load_public_dir_1 = require("./load_public_dir");
10
+ function withZephyr() {
11
+ // todo: set correctly
12
+ let bundle = {};
13
+ const vite_internal_options = {};
14
+ return {
15
+ name: 'with-zephyr',
16
+ enforce: 'post',
17
+ configResolved: (config) => tslib_1.__awaiter(this, void 0, void 0, function* () {
18
+ Object.assign(vite_internal_options, {
19
+ root: config.root,
20
+ configFile: config.configFile,
21
+ outDir: config.build.outDir,
22
+ publicDir: config.publicDir,
23
+ });
24
+ }),
25
+ writeBundle: (options, _bundle) => tslib_1.__awaiter(this, void 0, void 0, function* () {
26
+ bundle = _bundle;
27
+ }),
28
+ closeBundle: () => tslib_1.__awaiter(this, void 0, void 0, function* () {
29
+ const publicAssets = [];
30
+ if (vite_internal_options.publicDir) {
31
+ const _public_assets = yield (0, load_public_dir_1.load_public_dir)({
32
+ outDir: vite_internal_options.outDir,
33
+ publicDir: vite_internal_options.publicDir,
34
+ });
35
+ publicAssets.push(..._public_assets);
36
+ }
37
+ const _static_assets = yield (0, load_static_entries_1.load_static_entries)({
38
+ root: vite_internal_options.root,
39
+ outDir: vite_internal_options.outDir,
40
+ bundle,
41
+ });
42
+ publicAssets.push(..._static_assets);
43
+ const assets = Object.assign({}, bundle, ...publicAssets.map((asset) => ({ [asset.fileName]: asset })));
44
+ yield _zephyr({ assets, vite_internal_options });
45
+ }),
46
+ };
47
+ }
48
+ exports.withZephyr = withZephyr;
49
+ function _zephyr(options) {
50
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
51
+ const { assets: _assets, vite_internal_options } = options;
52
+ const path_to_execution_dir = vite_internal_options.root;
53
+ (0, zephyr_edge_contract_1.ze_log)('Configuring with Zephyr...');
54
+ const packageJson = yield (0, zephyr_agent_1.getPackageJson)(path_to_execution_dir);
55
+ (0, zephyr_edge_contract_1.ze_log)('Loaded package.json.', packageJson);
56
+ if (!packageJson)
57
+ return (0, zephyr_edge_contract_1.ze_error)('BU10010', 'package.json not found.');
58
+ const gitInfo = yield (0, zephyr_agent_1.getGitInfo)();
59
+ (0, zephyr_edge_contract_1.ze_log)('Loaded Git Info.', gitInfo);
60
+ if (!gitInfo || !(gitInfo === null || gitInfo === void 0 ? void 0 : gitInfo.app.org) || !(gitInfo === null || gitInfo === void 0 ? void 0 : gitInfo.app.project))
61
+ return (0, zephyr_edge_contract_1.ze_error)('BU10016', `Could not get git info. \n Can you confirm this directory has initialized as a git repository? `);
62
+ if (!(packageJson === null || packageJson === void 0 ? void 0 : packageJson.name))
63
+ return (0, zephyr_edge_contract_1.ze_error)('BU10013', 'package.json must have a name and version.');
64
+ const application_uid = (0, zephyr_edge_contract_1.createApplicationUID)({
65
+ org: gitInfo.app.org,
66
+ project: gitInfo.app.project,
67
+ name: packageJson === null || packageJson === void 0 ? void 0 : packageJson.name,
68
+ });
69
+ (0, zephyr_edge_contract_1.ze_log)('Going to check auth token or get it...');
70
+ yield (0, zephyr_agent_1.checkAuth)();
71
+ (0, zephyr_edge_contract_1.ze_log)('Got auth token, going to get application configuration and build id...');
72
+ const [appConfig, buildId, hash_set] = yield Promise.all([
73
+ (0, zephyr_agent_1.getApplicationConfiguration)({ application_uid }),
74
+ (0, zephyr_agent_1.getBuildId)(application_uid).catch((err) => {
75
+ logEvent({
76
+ level: 'error',
77
+ action: 'build:get-build-id:error',
78
+ message: `error receiving build number for '${email}'\n
79
+ ${err.message}\n`,
80
+ });
81
+ }),
82
+ (0, zephyr_agent_1.get_hash_list)(application_uid),
83
+ ]);
84
+ const { username, email, EDGE_URL } = appConfig;
85
+ (0, zephyr_edge_contract_1.ze_log)('Got application configuration', { username, email, EDGE_URL });
86
+ if (!buildId)
87
+ return (0, zephyr_edge_contract_1.ze_error)('BU10019', 'Could not get build id.');
88
+ const pluginOptions = {
89
+ pluginName: 'rollup-plugin-zephyr',
90
+ application_uid,
91
+ buildEnv: 'local',
92
+ username,
93
+ app: {
94
+ name: packageJson.name,
95
+ version: packageJson.version,
96
+ org: gitInfo.app.org,
97
+ project: gitInfo.app.project,
98
+ },
99
+ git: gitInfo === null || gitInfo === void 0 ? void 0 : gitInfo.git,
100
+ isCI,
101
+ zeConfig: {
102
+ user: username,
103
+ edge_url: EDGE_URL,
104
+ buildId,
105
+ },
106
+ mfConfig: void 0,
107
+ };
108
+ (0, zephyr_edge_contract_1.ze_log)('\nzephyr agent started.\n');
109
+ const logEvent = (0, zephyr_agent_1.logger)(pluginOptions);
110
+ const zeStart = Date.now();
111
+ const partialAssetMap = yield (0, zephyr_edge_contract_1.getPartialAssetMap)(application_uid);
112
+ yield (0, zephyr_edge_contract_1.removePartialAssetMap)(application_uid);
113
+ const assets = Object.assign({}, _assets, ...Object.values(partialAssetMap !== null && partialAssetMap !== void 0 ? partialAssetMap : {}));
114
+ const assetsMap = (0, zephyr_agent_1.buildAssetsMap)(assets, extractBuffer, getAssetType);
115
+ const missingAssets = (0, zephyr_agent_1.get_missing_assets)({ assetsMap, hash_set });
116
+ yield (0, zephyr_agent_1.upload)({
117
+ pluginOptions,
118
+ assets: {
119
+ assetsMap,
120
+ missingAssets,
121
+ outputPath: vite_internal_options.outDir,
122
+ count: Object.keys(assets).length,
123
+ },
124
+ getDashData: zephyr_agent_1.zeGetDashData,
125
+ appConfig,
126
+ zeStart,
127
+ uploadConfig: appConfig.uploadConfig,
128
+ });
129
+ });
130
+ }
131
+ function extractBuffer(asset) {
132
+ switch (asset.type) {
133
+ case 'chunk':
134
+ return asset.code;
135
+ case 'asset':
136
+ return typeof asset.source === 'string'
137
+ ? asset.source
138
+ : new TextDecoder().decode(asset.source);
139
+ default:
140
+ return void 0;
141
+ }
142
+ }
143
+ function getAssetType(asset) {
144
+ return asset.type;
145
+ }
146
+ //# sourceMappingURL=vite-plugin-zephyr.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vite-plugin-zephyr.js","sourceRoot":"","sources":["../../src/lib/vite-plugin-zephyr.ts"],"names":[],"mappings":";;;;AAMA,8BAA8B;AAG9B,+DAM8B;AAC9B,+CAYsB;AAEtB,+DAA4D;AAE5D,uDAAoD;AASpD,SAAgB,UAAU;IACxB,sBAAsB;IACtB,IAAI,MAAM,GAAiB,EAAE,CAAC;IAE9B,MAAM,qBAAqB,GAAG,E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K,CAAC,MAAM,KAAK,QAAQ;gBACrC,CAAC,CAAC,KAAK,CAAC,MAAM;gBACd,CAAC,CAAC,IAAI,WAAW,EAAE,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;QAC7C;YACE,OAAO,KAAK,CAAC,CAAC;IAClB,CAAC;AACH,CAAC;AAED,SAAS,YAAY,CAAC,KAAgC;IACpD,OAAO,KAAK,CAAC,IAAI,CAAC;AACpB,CAAC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"zephyr-internal-options.js","sourceRoot":"","sources":["../../src/lib/zephyr-internal-options.ts"],"names":[],"mappings":""}
@@ -0,0 +1,21 @@
1
+ {
2
+ "name": "vite-plugin-zephyr",
3
+ "version": "0.0.14",
4
+ "license": "Apache-2.0",
5
+ "main": "dist/index.js",
6
+ "types": "dist/index.d.ts",
7
+ "scripts": {
8
+ "build": "nx run vite-plugin-zephyr:build"
9
+ },
10
+ "dependencies": {
11
+ "vite": "^5",
12
+ "rollup": "^4",
13
+ "is-ci": "^3",
14
+ "zephyr-edge-contract": "workspace:*",
15
+ "zephyr-agent": "workspace:*"
16
+ },
17
+ "devDependencies": {
18
+ "@types/is-ci": "^3.0.4"
19
+ },
20
+ "type": "commonjs"
21
+ }
package/package.json CHANGED
@@ -1,17 +1,20 @@
1
1
  {
2
2
  "name": "vite-plugin-zephyr",
3
- "version": "0.0.12",
3
+ "version": "0.0.14",
4
4
  "license": "Apache-2.0",
5
+ "main": "dist/index.js",
6
+ "types": "dist/index.d.ts",
5
7
  "dependencies": {
6
8
  "vite": "^5",
7
9
  "rollup": "^4",
8
- "is-ci": "^3.0.1",
9
- "zephyr-edge-contract": "^0.0.12",
10
- "zephyr-agent": "^0.0.12"
10
+ "is-ci": "^3",
11
+ "zephyr-edge-contract": "0.0.14",
12
+ "zephyr-agent": "0.0.14"
11
13
  },
12
14
  "devDependencies": {
13
15
  "@types/is-ci": "^3.0.4"
14
16
  },
15
- "main": "./src/index.js",
16
- "type": "commonjs"
17
- }
17
+ "scripts": {
18
+ "build": "nx run vite-plugin-zephyr:build"
19
+ }
20
+ }
package/src/index.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../libs/vite-plugin-zephyr/src/index.ts"],"names":[],"mappings":";;;AAAA,+DAAsD;AAA7C,gHAAA,UAAU,OAAA;AACnB,+EAAqE;AAA5D,+HAAA,iBAAiB,OAAA"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"load_extra_files_from_dist.js","sourceRoot":"","sources":["../../../../../libs/vite-plugin-zephyr/src/lib/load_extra_files_from_dist.ts"],"names":[],"mappings":";;;;AACA,yCAA8C;AAC9C,qCAA0D;AAC1D,+BAAqC;AACrC,yCAAsC;AAOtC,SAAsB,0BAA0B,CAC9C,KAAoC;;QAEpC,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,KAAK,CAAC;QAC/B,MAAM,YAAY,GAAkB,EAAE,CAAC;QAEvC,MAAM,aAAa,GAAG,IAAA,mBAAO,EAAC,IAAI,EAAE,MAAM,CAAC,CAAC;QAC5C,MAAM,OAAO,GAAG,CAAO,OAAe,EAAE,EAAE;YACxC,KAAK,MAAM,IAAI,IAAI,IAAA,qBAAW,EAAC,OAAO,CAAC,EAAE,CAAC;gBACxC,MAAM,QAAQ,GAAG,IAAA,mBAAO,EAAC,OAAO,EAAE,IAAI,CAAC,CAAC;gBACxC,MAAM,IAAI,GAAG,IAAA,kBAAQ,EAAC,QAAQ,CAAC,CAAC;gBAChC,IAAI,IAAI,CAAC,WAAW,EAAE,EAAE,CAAC;oBACvB,MAAM,OAAO,CAAC,QAAQ,CAAC,CAAC;oBACxB,SAAS;gBACX,CAAC;gBACD,MAAM,QAAQ,GAAG,IAAA,oBAAa,EAAC,IAAA,oBAAQ,EAAC,aAAa,EAAE,QAAQ,CAAC,CAAC,CAAC;gBAClE,IAAI,CAAC,CAAC,QAAQ,IAAI,MAAM,CAAC,EAAE,CAAC;oBAC1B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C,IAAI,CAAC;wBAChB,QAAQ,EAAE,IAAA,oBAAa,EAAC,IAAA,oBAAQ,EAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;wBACnD,IAAI,EAAE,IAAA,oBAAQ,EAAC,IAAI,CAAC;wBACpB,kBAAkB,EAAE,KAAK;wBACzB,MAAM,EAAE,MAAM,IAAA,qBAAS,EAAC,kBAAQ,CAAC,CAAC,OAAO,CAAC;wBAC1C,IAAI,EAAE,OAAO;qBACd,CAAC,CAAC;gBACL,CAAC;YACH,CAAC;QACH,CAAC,CAAA,CAAC;QACF,MAAM,OAAO,CAAC,SAAS,EAAE,MAAM,CAAC,CAAC;QACjC,OAAO,YAAY,CAAC;IACtB,CAAC;CAAA;AA7BD,0CA6BC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"load_static_entries.js","sourceRoot":"","sources":["../../../../../libs/vite-plugin-zephyr/src/lib/load_static_entries.ts"],"names":[],"mappings":";;;;AACA,yCAA8C;AAC9C,qCAA0D;AAC1D,+BAAqC;AACrC,yCAAsC;AAOtC,MAAM,aAAa,GAA4B;IAC7C,YAAY,EAAE,IAAI;IAClB,UAAU,EAAE,IAAI;IAChB,aAAa,EAAE,IAAI;CACpB,CAAC;AAEF,SAAsB,mBAAmB,CACvC,KAA+B;;QAE/B,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,KAAK,CAAC;QAC/B,MAAM,YAAY,GAAkB,EAAE,CAAC;QAEvC,MAAM,aAAa,GAAG,IAAA,mBAAO,EAAC,IAAI,EAAE,MAAM,CAAC,CAAC;QAE5C,MAAM,OAAO,GAAG,CAAO,OAAe,EAAE,EAAE;YACxC,KAAK,MAAM,IAAI,IAAI,IAAA,qBAAW,EAAC,OAAO,CAAC,EAAE,CAAC;gBACxC,MAAM,QAAQ,GAAG,IAAA,mBAAO,EAAC,OAAO,EAAE,IAAI,CAAC,CAAC;gBACxC,MAAM,IAAI,GAAG,IAAA,kBAAQ,EAAC,QAAQ,CAAC,CAAC;gBAChC,IAAI,IAAI,CAAC,WAAW,EAAE,EAAE,CAAC;oBACvB,MAAM,OAAO,CAAC,QAAQ,CAAC,CAAC;oBACxB,SAAS;gBACX,CAAC;gBACD,MAAM,QAAQ,GAAG,IAAA,oBAAa,EAAC,IAAA,oBAAQ,EAAC,aAAa,EAAE,QAAQ,CAAC,CAAC,CAAC;gBAClE,IAAI,aAAa,CAAC,IAAI,CAAC,EAAE,CAAC;oBACxB,YAAY,CAAC,IAAI,CAAC;wBAChB,QAAQ;wBACR,IAAI,EAAE,IAAI;wBACV,kBAAkB,EAAE,KAAK;wBACzB,MAAM,EAAE,MAAM,IAAA,qBAAS,EAAC,kBAAQ,CAAC,CAAC,QAAQ,CAAC;wBAC3C,IAAI,EAAE,OAAO;qBACd,CAAC,CAAC;gBACL,CAAC;YACH,CAAC;QACH,CAAC,CAAA,CAAC;QACF,MAAM,OAAO,CAAC,aAAa,CAAC,CAAC;QAC7B,OAAO,YAAY,CAAC;IACtB,CAAC;CAAA;AA9BD,kDA8BC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"vite-plugin-zephyr-partial.js","sourceRoot":"","sources":["../../../../../libs/vite-plugin-zephyr/src/lib/vite-plugin-zephyr-partial.ts"],"names":[],"mappings":";;;;AAOA,8BAA8B;AAE9B,+DAM8B;AAC9B,+CAWsB;AAEtB,uDAAoD;AACpD,6EAA0E;AAG1E,SAAgB,iBAAiB;IAC/B,IAAI,MAAM,GAAiB,EAAE,CAAC;IAC9B,MAAM,qBAAqB,GAAG,EAA2B,CAAC;IAE1D,OAAO;QACL,IAAI,EAAE,qBAAqB;QAC3B,KAAK,EAAE,OAAO;QACd,OAAO,EAAE,MAAM;QACf,cAAc,EAAE,CAAO,MAAsB,EAAE,EAAE;YAC/C,MAAM,CAAC,MAAM,CAAC,qBAAqB,EAAE;gBACnC,IAAI,EAAE,MAAM,CAAC,IAAI;gBACjB,UAAU,EAAE,MAAM,CAAC,UAAU;gBAC7B,MAAM,EAAE,MAAM,CAAC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AAC,CAAC,KAAK,CACzE,CAAC,GAAG,EAAE,EAAE,CAAC,IAAA,+BAAQ,EAAC,4BAA4B,EAAE,GAAG,CAAC,CACrD,CAAC;QAEF,IAAI,OAAO,aAAa,KAAK,WAAW;YACtC,OAAO,IAAA,+BAAQ,EAAC,yCAAyC,CAAC,CAAC;QAE7D,MAAM,mBAAmB,GAAG,MAAM,IAAA,6BAAc,EAAC,aAAa,EAAE;YAC9D,aAAa;YACb,SAAS;YACT,KAAK,EAAE,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,MAAM;SAClC,CAAC,CAAC;QAEH,IAAI,CAAC,mBAAmB;YACtB,OAAO,IAAA,+BAAQ,EAAC,0BAA0B,EAAE,mBAAmB,CAAC,CAAC;QAEnE,MAAM,IAAA,0CAAmB,EACvB,eAAe,EACf,MAAA,qBAAqB,CAAC,UAAU,mCAAI,SAAS,EAC7C,SAAS,CACV,CAAC;QAEF,QAAQ,CAAC;YACP,KAAK,EAAE,MAAM;YACb,MAAM,EAAE,mBAAmB;YAC3B,OAAO,EAAE,qBAAqB,IAAI,CAAC,GAAG,EAAE,GAAG,OAAO,IAAI;SACvD,CAAC,CAAC;IACL,CAAC;CAAA"}
@@ -1,9 +0,0 @@
1
- import { NormalizedOutputOptions, OutputBundle } from 'rollup';
2
- import { ResolvedConfig } from 'vite';
3
- export declare function withZephyr(): {
4
- name: string;
5
- enforce: string;
6
- configResolved: (config: ResolvedConfig) => Promise<void>;
7
- writeBundle: (options: NormalizedOutputOptions, _bundle: OutputBundle) => Promise<void>;
8
- closeBundle: () => Promise<void>;
9
- };
@@ -1,212 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.withZephyr = void 0;
4
- const tslib_1 = require("tslib");
5
- const isCI = require("is-ci");
6
- const zephyr_edge_contract_1 = require("zephyr-edge-contract");
7
- const zephyr_agent_1 = require("zephyr-agent");
8
- const load_static_entries_1 = require("./load_static_entries");
9
- function withZephyr() {
10
- // todo: set correctly
11
- let bundle = {};
12
- const vite_internal_options = {};
13
- return {
14
- name: 'with-zephyr',
15
- enforce: 'post',
16
- configResolved: (config) => tslib_1.__awaiter(this, void 0, void 0, function* () {
17
- Object.assign(vite_internal_options, {
18
- root: config.root,
19
- configFile: config.configFile,
20
- outDir: config.build.outDir,
21
- publicDir: config.publicDir,
22
- });
23
- }),
24
- writeBundle: (options, _bundle) => tslib_1.__awaiter(this, void 0, void 0, function* () {
25
- bundle = _bundle;
26
- }),
27
- closeBundle: () => tslib_1.__awaiter(this, void 0, void 0, function* () {
28
- const publicAssets = [];
29
- const _static_assets = yield (0, load_static_entries_1.load_static_entries)({
30
- root: vite_internal_options.root,
31
- bundle,
32
- });
33
- publicAssets.push(..._static_assets);
34
- const assets = Object.assign({}, bundle, ...publicAssets.map((asset) => ({ [asset.fileName]: asset })));
35
- yield _zephyr({ assets, vite_internal_options });
36
- }),
37
- };
38
- }
39
- exports.withZephyr = withZephyr;
40
- function _zephyr(options) {
41
- return tslib_1.__awaiter(this, void 0, void 0, function* () {
42
- const { assets, vite_internal_options } = options;
43
- const path_to_execution_dir = vite_internal_options.root;
44
- (0, zephyr_edge_contract_1.ze_log)('Configuring with Zephyr');
45
- const packageJson = (0, zephyr_agent_1.getPackageJson)(path_to_execution_dir);
46
- (0, zephyr_edge_contract_1.ze_log)('Loaded Package JSON', packageJson);
47
- if (!packageJson)
48
- return (0, zephyr_edge_contract_1.ze_error)('Could not find package json');
49
- const gitInfo = (0, zephyr_agent_1.getGitInfo)();
50
- (0, zephyr_edge_contract_1.ze_log)('Loaded Git Info', gitInfo);
51
- if (!gitInfo ||
52
- !(gitInfo === null || gitInfo === void 0 ? void 0 : gitInfo.app.org) ||
53
- !(gitInfo === null || gitInfo === void 0 ? void 0 : gitInfo.app.project) ||
54
- !(packageJson === null || packageJson === void 0 ? void 0 : packageJson.name))
55
- return (0, zephyr_edge_contract_1.ze_error)('Could not get git info');
56
- const application_uid = (0, zephyr_edge_contract_1.createFullAppName)({
57
- org: gitInfo.app.org,
58
- project: gitInfo.app.project,
59
- name: packageJson === null || packageJson === void 0 ? void 0 : packageJson.name,
60
- });
61
- (0, zephyr_edge_contract_1.ze_log)('Going to check auth token or get it');
62
- yield (0, zephyr_agent_1.checkAuth)();
63
- (0, zephyr_edge_contract_1.ze_log)('Got auth token, going to get application configuration');
64
- const { username, email, EDGE_URL } = yield (0, zephyr_agent_1.getApplicationConfiguration)({
65
- application_uid,
66
- });
67
- (0, zephyr_edge_contract_1.ze_log)('Got application configuration', { username, email, EDGE_URL });
68
- (0, zephyr_edge_contract_1.ze_log)('Going to get build id');
69
- const buildId = yield (0, zephyr_agent_1.getBuildId)(application_uid).catch((err) => {
70
- logEvent({
71
- level: 'error',
72
- action: 'build:get-build-id:error',
73
- message: `error receiving build number for '${email}'\n
74
- ${err.message}\n`,
75
- });
76
- });
77
- if (!buildId)
78
- return (0, zephyr_edge_contract_1.ze_error)('[zephyr]: Could not get build id');
79
- const pluginOptions = {
80
- pluginName: 'rollup-plugin-zephyr',
81
- application_uid,
82
- buildEnv: 'local',
83
- username,
84
- app: {
85
- name: packageJson.name,
86
- version: packageJson.version,
87
- org: gitInfo.app.org,
88
- project: gitInfo.app.project,
89
- },
90
- git: gitInfo === null || gitInfo === void 0 ? void 0 : gitInfo.git,
91
- isCI,
92
- zeConfig: {
93
- user: username,
94
- edge_url: EDGE_URL,
95
- buildId,
96
- },
97
- mfConfig: void 0,
98
- };
99
- (0, zephyr_edge_contract_1.ze_log)('zephyr agent started.');
100
- const logEvent = (0, zephyr_agent_1.logger)(pluginOptions);
101
- const zeStart = Date.now();
102
- const extractBuffer = (asset) => {
103
- switch (asset.type) {
104
- case 'chunk':
105
- return asset.code;
106
- case 'asset':
107
- return typeof asset.source === 'string'
108
- ? asset.source
109
- : new TextDecoder().decode(asset.source);
110
- default:
111
- return void 0;
112
- }
113
- };
114
- const getAssetType = (asset) => asset.type;
115
- const assetsMap = Object.keys(assets).reduce((memo, filepath) => {
116
- const asset = assets[filepath];
117
- const buffer = extractBuffer(asset);
118
- if (!buffer) {
119
- logEvent({
120
- action: 'ze:build:assets:unknown-asset-type',
121
- level: 'error',
122
- message: `unknown asset type: ${getAssetType(asset)}`,
123
- });
124
- 1;
125
- return memo;
126
- }
127
- const assetMap = (0, zephyr_agent_1.getZeBuildAsset)({ filepath, content: buffer });
128
- memo[assetMap.hash] = assetMap;
129
- return memo;
130
- }, {});
131
- const partialAssetMap = yield (0, zephyr_edge_contract_1.getPartialAssetMap)(application_uid);
132
- yield (0, zephyr_edge_contract_1.removePartialAssetMap)(application_uid);
133
- const snapshot = (0, zephyr_agent_1.createSnapshot)({
134
- options: pluginOptions,
135
- assets: Object.assign({}, assetsMap, ...Object.values(partialAssetMap !== null && partialAssetMap !== void 0 ? partialAssetMap : {})),
136
- username,
137
- email,
138
- });
139
- const missingAssets = yield (0, zephyr_agent_1.zeUploadSnapshot)(pluginOptions, snapshot).catch((err) => (0, zephyr_edge_contract_1.ze_error)('Failed to upload snapshot.', err));
140
- if (typeof missingAssets === 'undefined')
141
- return (0, zephyr_edge_contract_1.ze_error)('Snapshot upload gave no result, exiting');
142
- const assetsUploadSuccess = yield (0, zephyr_agent_1.zeUploadAssets)(pluginOptions, {
143
- missingAssets,
144
- assetsMap,
145
- count: Object.keys(assets).length,
146
- });
147
- if (!assetsUploadSuccess)
148
- return (0, zephyr_edge_contract_1.ze_error)('Failed to upload assets.', assetsUploadSuccess);
149
- const version = (0, zephyr_edge_contract_1.createSnapshotId)(pluginOptions);
150
- const dashData = {
151
- id: pluginOptions.application_uid,
152
- name: packageJson.name,
153
- // name: pluginOptions.mfConfig?.name,
154
- edge: { url: EDGE_URL },
155
- app: Object.assign({}, pluginOptions.app, {
156
- buildId: pluginOptions.zeConfig.buildId,
157
- }),
158
- version,
159
- git: pluginOptions.git,
160
- // remote: pluginOptions.mfConfig?.filename,
161
- // remotes: Object.keys(pluginOptions.mfConfig?.remotes || {}),
162
- context: {
163
- isCI: pluginOptions.isCI,
164
- },
165
- dependencies: [],
166
- devDependencies: [],
167
- optionalDependencies: [],
168
- metadata: {},
169
- overrides: [
170
- /* {
171
- "id": "react-dom",
172
- "name": "react-dom",
173
- "version": "18.2.0",
174
- "location": "react-dom",
175
- "applicationID": "react-dom"
176
- },
177
- {
178
- "id": "react",
179
- "name": "react",
180
- "version": "18.2.0",
181
- "location": "react",
182
- "applicationID": "react"
183
- }*/
184
- ],
185
- consumes: [],
186
- modules: [
187
- /* {
188
- "id": "GreenRecos:GreenRecos",
189
- "name": "GreenRecos",
190
- "applicationID": "GreenRecos",
191
- "requires": [
192
- "react"
193
- ],
194
- "file": "./src/app/team-green-recos.tsx"
195
- }*/
196
- ],
197
- sha: pluginOptions.git.commit,
198
- // todo: @deprecate
199
- buildHash: pluginOptions.git.commit,
200
- };
201
- const envs = yield (0, zephyr_agent_1.zeUploadBuildStats)(dashData);
202
- if (!envs)
203
- return (0, zephyr_edge_contract_1.ze_error)('Did not receive envs from build stats upload. Exiting.');
204
- yield (0, zephyr_agent_1.zeEnableSnapshotOnEdge)(pluginOptions, snapshot, envs.value);
205
- logEvent({
206
- level: 'info',
207
- action: 'build:deploy:done',
208
- message: `build deployed in ${Date.now() - zeStart}ms`,
209
- });
210
- });
211
- }
212
- //# sourceMappingURL=vite-plugin-zephyr.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"vite-plugin-zephyr.js","sourceRoot":"","sources":["../../../../../libs/vite-plugin-zephyr/src/lib/vite-plugin-zephyr.ts"],"names":[],"mappings":";;;;AAMA,8BAA8B;AAG9B,+DAQ8B;AAC9B,+CAasB;AAEtB,+DAA4D;AAU5D,SAAgB,UAAU;IACxB,sBAAsB;IACtB,IAAI,MAAM,GAAiB,EAAE,CAAC;IAE9B,MAAM,qBAAqB,GAAG,EAAkC,CAAC;IAEjE,OAAO;QACL,IAAI,EAAE,aAAa;QACnB,OAAO,EAAE,MAAM;QACf,cAAc,EAAE,CAAO,MAAsB,EAAE,EAAE;YAC/C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;yBAQa;aACd;YACD,GAAG,EAAE,aAAa,CAAC,GAAG,CAAC,MAAM;YAC7B,mBAAmB;YACnB,SAAS,EAAE,aAAa,CAAC,GAAG,CAAC,MAAM;SACpC,CAAC;QAEF,MAAM,IAAI,GAAG,MAAM,IAAA,iCAAkB,EAAC,QAAQ,CAAC,CAAC;QAChD,IAAI,CAAC,IAAI;YACP,OAAO,IAAA,+BAAQ,EAAC,wDAAwD,CAAC,CAAC;QAE5E,MAAM,IAAA,qCAAsB,EAAC,aAAa,EAAE,QAAQ,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC;QAElE,QAAQ,CAAC;YACP,KAAK,EAAE,MAAM;YACb,MAAM,EAAE,mBAAmB;YAC3B,OAAO,EAAE,qBAAqB,IAAI,CAAC,GAAG,EAAE,GAAG,OAAO,IAAI;SACvD,CAAC,CAAC;IACL,CAAC;CAAA"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"zephyr-internal-options.js","sourceRoot":"","sources":["../../../../../libs/vite-plugin-zephyr/src/lib/zephyr-internal-options.ts"],"names":[],"mappings":""}
File without changes
File without changes
File without changes
File without changes
File without changes