zcatalyst-cli 1.25.2 → 1.26.0

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.
Files changed (263) hide show
  1. package/lib/api-timer.d.ts +0 -1
  2. package/lib/apig-utils.d.ts +1 -1
  3. package/lib/apig-utils.js +1 -1
  4. package/lib/appsail-utils.js +80 -13
  5. package/lib/archiver.d.ts +0 -4
  6. package/lib/archiver.js +21 -11
  7. package/lib/authentication/constants/auth.js +1 -1
  8. package/lib/authentication/credential.js +3 -3
  9. package/lib/authentication/index.js +25 -14
  10. package/lib/authentication/login.d.ts +0 -2
  11. package/lib/authentication/login.js +23 -10
  12. package/lib/bin/catalyst.js +17 -7
  13. package/lib/client-utils.d.ts +3 -3
  14. package/lib/client-utils.js +2 -2
  15. package/lib/client.js +19 -9
  16. package/lib/code-deck.d.ts +0 -2
  17. package/lib/code-deck.js +4 -4
  18. package/lib/command_needs/config.js +1 -1
  19. package/lib/command_needs/rc.js +5 -2
  20. package/lib/commands/appsail/add.js +17 -7
  21. package/lib/commands/client/setup.js +17 -7
  22. package/lib/commands/config/set.js +5 -3
  23. package/lib/commands/deploy/appsail.js +37 -14
  24. package/lib/commands/deploy/index.js +88 -66
  25. package/lib/commands/deploy/slate.js +37 -14
  26. package/lib/commands/event/generate/integ.js +18 -9
  27. package/lib/commands/functions/add.js +17 -7
  28. package/lib/commands/functions/execute.js +17 -7
  29. package/lib/commands/functions/setup.js +17 -7
  30. package/lib/commands/functions/shell.js +17 -7
  31. package/lib/commands/iac/import.js +18 -8
  32. package/lib/commands/iac/pack.js +17 -7
  33. package/lib/commands/iac/status.js +17 -7
  34. package/lib/commands/index.js +20 -12
  35. package/lib/commands/init.js +17 -7
  36. package/lib/commands/login.js +17 -7
  37. package/lib/commands/logout.js +17 -7
  38. package/lib/commands/project/list.js +17 -7
  39. package/lib/commands/project/use.js +1 -0
  40. package/lib/commands/pull.js +17 -7
  41. package/lib/commands/run.js +17 -7
  42. package/lib/commands/serve.js +17 -7
  43. package/lib/commands/signals/generate/index.js +1 -1
  44. package/lib/commands/slate/create.js +17 -7
  45. package/lib/commands/slate/link.js +18 -7
  46. package/lib/commands/slate/unlink.js +16 -4
  47. package/lib/commands/token/generate.js +17 -7
  48. package/lib/commands/token/list.js +17 -7
  49. package/lib/commands/token/revoke.js +17 -7
  50. package/lib/commands/zest/generate/index.js +21 -11
  51. package/lib/deploy/features/appsail/index.js +2 -3
  52. package/lib/deploy/features/appsail/pack.d.ts +0 -1
  53. package/lib/deploy/features/appsail/pack.js +2 -3
  54. package/lib/deploy/features/appsail/utils.js +7 -8
  55. package/lib/deploy/features/functions/languages/index.js +3 -4
  56. package/lib/deploy/features/index.js +17 -7
  57. package/lib/deploy/features/slate.js +2 -3
  58. package/lib/deploy/index.js +2 -2
  59. package/lib/deploy/util.d.ts +2 -0
  60. package/lib/deploy/util.js +3 -1
  61. package/lib/docs/commands/signals/generate/generate.toml +19 -0
  62. package/lib/docs/commands/slate/unlink.toml +9 -0
  63. package/lib/docs/fn-utils/lib/node.toml +4 -0
  64. package/lib/docs/init/dependencies/python/ensure-python.toml +4 -0
  65. package/lib/docs/serve/server/lib/slate/index.toml +15 -0
  66. package/lib/docs/slate-utils.toml +9 -0
  67. package/lib/endpoints/index.d.ts +2 -1
  68. package/lib/endpoints/index.js +88 -79
  69. package/lib/endpoints/lib/apig.d.ts +0 -1
  70. package/lib/endpoints/lib/apig.js +2 -2
  71. package/lib/endpoints/lib/applogic.d.ts +0 -1
  72. package/lib/endpoints/lib/applogic.js +2 -2
  73. package/lib/endpoints/lib/appsail.d.ts +1 -4
  74. package/lib/endpoints/lib/appsail.js +7 -7
  75. package/lib/endpoints/lib/client.d.ts +0 -1
  76. package/lib/endpoints/lib/code-deck.js +1 -1
  77. package/lib/endpoints/lib/common.d.ts +0 -2
  78. package/lib/endpoints/lib/ds-bulk.js +2 -2
  79. package/lib/endpoints/lib/env.js +2 -2
  80. package/lib/endpoints/lib/filestore.d.ts +0 -1
  81. package/lib/endpoints/lib/functions.d.ts +0 -1
  82. package/lib/endpoints/lib/functions.js +2 -2
  83. package/lib/endpoints/lib/git-hub.d.ts +0 -2
  84. package/lib/endpoints/lib/iac.d.ts +0 -3
  85. package/lib/endpoints/lib/iac.js +2 -2
  86. package/lib/endpoints/lib/project.d.ts +0 -1
  87. package/lib/endpoints/lib/project.js +2 -2
  88. package/lib/endpoints/lib/sdk.d.ts +0 -2
  89. package/lib/endpoints/lib/sdk.js +1 -1
  90. package/lib/endpoints/lib/slate.d.ts +0 -1
  91. package/lib/endpoints/lib/stratus.d.ts +0 -1
  92. package/lib/endpoints/lib/user.d.ts +0 -2
  93. package/lib/endpoints/lib/user.js +2 -1
  94. package/lib/error/context-help.js +1 -1
  95. package/lib/error/index.js +2 -2
  96. package/lib/event_generate/cache.js +4 -4
  97. package/lib/event_generate/custom.js +1 -2
  98. package/lib/event_generate/datastore.js +4 -4
  99. package/lib/event_generate/filestore.js +4 -4
  100. package/lib/event_generate/github.js +2 -2
  101. package/lib/event_generate/index.js +19 -11
  102. package/lib/event_generate/stratus.js +2 -2
  103. package/lib/event_generate/user.js +2 -2
  104. package/lib/event_generate/webapp.js +2 -2
  105. package/lib/execute/caller.d.ts +0 -1
  106. package/lib/execute/caller.js +20 -7
  107. package/lib/execute/index.js +27 -4
  108. package/lib/execute-script.js +22 -13
  109. package/lib/express_middlewares/auth-checker.js +2 -3
  110. package/lib/express_middlewares/project.d.ts +1 -1
  111. package/lib/fn-utils/index.js +17 -7
  112. package/lib/fn-utils/lib/browserLogic.js +4 -5
  113. package/lib/fn-utils/lib/common.d.ts +0 -1
  114. package/lib/fn-utils/lib/common.js +25 -26
  115. package/lib/fn-utils/lib/integ.js +2 -3
  116. package/lib/fn-utils/lib/java/classpath.js +2 -3
  117. package/lib/fn-utils/lib/java/compile.js +4 -4
  118. package/lib/fn-utils/lib/java/ensure-java-userconfig.d.ts +10 -0
  119. package/lib/fn-utils/lib/java/ensure-java-userconfig.js +45 -23
  120. package/lib/fn-utils/lib/java/index.d.ts +0 -1
  121. package/lib/fn-utils/lib/java/index.js +11 -11
  122. package/lib/fn-utils/lib/java/keywords.js +2 -2
  123. package/lib/fn-utils/lib/node.d.ts +1 -1
  124. package/lib/fn-utils/lib/node.js +67 -15
  125. package/lib/fn-utils/lib/python.js +29 -19
  126. package/lib/iac/status/util/index.d.ts +1 -1
  127. package/lib/init/dependencies/npm-install.js +2 -2
  128. package/lib/init/dependencies/python/ensure-python.d.ts +2 -2
  129. package/lib/init/dependencies/python/ensure-python.js +65 -58
  130. package/lib/init/dependencies/python/pip-install.d.ts +3 -5
  131. package/lib/init/dependencies/python/pip-install.js +14 -53
  132. package/lib/init/features/appsail/utils.js +21 -12
  133. package/lib/init/features/client/index.js +18 -9
  134. package/lib/init/features/client/initializers/angular.js +17 -7
  135. package/lib/init/features/client/initializers/basic.js +17 -7
  136. package/lib/init/features/client/initializers/lyte.js +17 -7
  137. package/lib/init/features/client/initializers/react.js +17 -7
  138. package/lib/init/features/index.js +29 -20
  139. package/lib/init/features/project.js +5 -5
  140. package/lib/init/features/slate/index.js +198 -69
  141. package/lib/init/util/client.js +23 -13
  142. package/lib/init/util/common.js +5 -6
  143. package/lib/init/util/project.js +1 -1
  144. package/lib/internal/api.d.ts +0 -3
  145. package/lib/internal/api.js +19 -9
  146. package/lib/internal/command.js +18 -9
  147. package/lib/migration/global/1.25.0.d.ts +2 -0
  148. package/lib/migration/global/1.25.0.js +28 -0
  149. package/lib/migration/index.js +20 -12
  150. package/lib/option-filter.js +19 -10
  151. package/lib/optional-import.js +19 -10
  152. package/lib/plugin-loader.d.ts +0 -2
  153. package/lib/plugin-loader.js +18 -8
  154. package/lib/port-resolver.js +10 -10
  155. package/lib/prompt/index.d.ts +3 -3
  156. package/lib/prompt/index.js +17 -7
  157. package/lib/prompt/types/file-path.d.ts +0 -1
  158. package/lib/prompt/types/search-box.d.ts +0 -1
  159. package/lib/prompt/types/tree.d.ts +1 -2
  160. package/lib/prompt/types/tree.js +10 -10
  161. package/lib/prompt/types/with-description.d.ts +0 -1
  162. package/lib/pull/features/functions/index.js +71 -52
  163. package/lib/pull/features/functions/languages.js +3 -4
  164. package/lib/pull/features/index.js +17 -7
  165. package/lib/repl-server.d.ts +0 -1
  166. package/lib/repl-server.js +9 -1
  167. package/lib/serve/features/apig.js +19 -1
  168. package/lib/serve/features/appsail.d.ts +1 -0
  169. package/lib/serve/features/appsail.js +51 -7
  170. package/lib/serve/features/index.js +22 -13
  171. package/lib/serve/index.js +20 -7
  172. package/lib/serve/server/index.d.ts +0 -2
  173. package/lib/serve/server/index.js +26 -12
  174. package/lib/serve/server/lib/appsail/index.js +31 -37
  175. package/lib/serve/server/lib/appsail/start.js +12 -5
  176. package/lib/serve/server/lib/appsail/util.d.ts +11 -0
  177. package/lib/serve/server/lib/appsail/util.js +69 -0
  178. package/lib/serve/server/lib/java/index.js +18 -7
  179. package/lib/serve/server/lib/master/appsail.js +3 -4
  180. package/lib/serve/server/lib/master/functions.js +1 -2
  181. package/lib/serve/server/lib/master/index.d.ts +0 -1
  182. package/lib/serve/server/lib/master/index.js +5 -5
  183. package/lib/serve/server/lib/master/slate.js +1 -2
  184. package/lib/serve/server/lib/master/unknown-req-proxy.js +5 -2
  185. package/lib/serve/server/lib/master/utils.d.ts +4 -8
  186. package/lib/serve/server/lib/master/utils.js +4 -6
  187. package/lib/serve/server/lib/master/web-client.js +1 -2
  188. package/lib/serve/server/lib/node/index.js +22 -11
  189. package/lib/serve/server/lib/node/server/browserlogic/utils/playwright-handler.js +1 -1
  190. package/lib/serve/server/lib/node/server/browserlogic/utils/puppeteer-handler.js +1 -1
  191. package/lib/serve/server/lib/node/server/browserlogic/utils/selenium-handler.js +2 -0
  192. package/lib/serve/server/lib/python/index.js +23 -14
  193. package/lib/serve/server/lib/slate/static-server.d.ts +0 -1
  194. package/lib/serve/server/lib/slate/static-server.js +5 -4
  195. package/lib/serve/server/lib/web_client/server.d.ts +0 -1
  196. package/lib/serve/server/lib/web_client/server.js +5 -4
  197. package/lib/shell/dependencies/http-functions.d.ts +0 -2
  198. package/lib/shell/dependencies/http-functions.js +7 -7
  199. package/lib/shell/dependencies/non-http-function/fn-execution-handler.d.ts +0 -2
  200. package/lib/shell/dependencies/non-http-function/fn-execution-handler.js +55 -24
  201. package/lib/shell/dependencies/non-http-function/fn-handler.d.ts +3 -3
  202. package/lib/shell/dependencies/non-http-function/fn-handler.js +54 -20
  203. package/lib/shell/dependencies/non-http-function/node.js +4 -4
  204. package/lib/shell/dependencies/non-http-function/python.d.ts +1 -1
  205. package/lib/shell/dependencies/non-http-function/python.js +11 -13
  206. package/lib/shell/dependencies/non-http-function/slave-manager.d.ts +0 -2
  207. package/lib/shell/dependencies/non-http-function/slave-manager.js +11 -7
  208. package/lib/shell/dependencies/tunnel-server.js +4 -4
  209. package/lib/shell/index.js +50 -3
  210. package/lib/shell/prepare/index.js +4 -3
  211. package/lib/shell/prepare/languages/index.js +18 -9
  212. package/lib/shell/prepare/languages/node.js +29 -19
  213. package/lib/shell/prepare/languages/python.js +6 -12
  214. package/lib/signals/index.js +19 -11
  215. package/lib/slate-utils.js +4 -3
  216. package/lib/throbber/index.d.ts +1 -2
  217. package/lib/throbber/index.js +5 -2
  218. package/lib/throbber/utils.d.ts +0 -1
  219. package/lib/throbber/utils.js +4 -5
  220. package/lib/userConfig.d.ts +14 -0
  221. package/lib/userConfig.js +15 -1
  222. package/lib/util_modules/config/index.js +17 -7
  223. package/lib/util_modules/config/lib/apig.d.ts +1 -0
  224. package/lib/util_modules/config/lib/apig.js +10 -5
  225. package/lib/util_modules/config/lib/appsail.js +7 -7
  226. package/lib/util_modules/config/lib/client.js +5 -6
  227. package/lib/util_modules/config/lib/functions.js +5 -6
  228. package/lib/util_modules/config/lib/slate.js +5 -6
  229. package/lib/util_modules/config-store.d.ts +1 -1
  230. package/lib/util_modules/config-store.js +30 -13
  231. package/lib/util_modules/constants/lib/apig-rules.d.ts +1 -1
  232. package/lib/util_modules/constants/lib/dc-type.js +3 -3
  233. package/lib/util_modules/constants/lib/placeholders.d.ts +1 -1
  234. package/lib/util_modules/constants/lib/placeholders.js +1 -1
  235. package/lib/util_modules/constants/lib/urls.js +2 -9
  236. package/lib/util_modules/container.js +23 -14
  237. package/lib/util_modules/dc.js +3 -4
  238. package/lib/util_modules/env.d.ts +3 -0
  239. package/lib/util_modules/env.js +64 -4
  240. package/lib/util_modules/event-emitter.d.ts +9 -0
  241. package/lib/util_modules/event-emitter.js +68 -0
  242. package/lib/util_modules/fs/index.js +17 -7
  243. package/lib/util_modules/fs/lib/async.d.ts +0 -4
  244. package/lib/util_modules/fs/lib/async.js +46 -46
  245. package/lib/util_modules/fs/lib/sync.d.ts +1 -3
  246. package/lib/util_modules/fs/lib/sync.js +40 -30
  247. package/lib/util_modules/logger/index.js +12 -12
  248. package/lib/util_modules/logger/utils.d.ts +0 -4
  249. package/lib/util_modules/logger/utils.js +1 -1
  250. package/lib/util_modules/logger/winston.js +2 -2
  251. package/lib/util_modules/option.js +5 -6
  252. package/lib/util_modules/project.js +22 -23
  253. package/lib/util_modules/runtime-store.d.ts +2 -2
  254. package/lib/util_modules/server.d.ts +1 -2
  255. package/lib/util_modules/server.js +54 -15
  256. package/lib/util_modules/shell.d.ts +0 -3
  257. package/lib/util_modules/shell.js +5 -6
  258. package/lib/util_modules/toml.js +2 -3
  259. package/package.json +13 -13
  260. package/templates/init/functions/java/event/sample.java +5 -2
  261. package/templates/web-socket.txt +1 -1
  262. /package/lib/docs/{commands/event/generate → event_generate}/index.toml +0 -0
  263. /package/templates/init/functions/java/integ/convokraft/{Sample.java → sample.java} +0 -0
@@ -0,0 +1,68 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.CatalystEventEmitter = void 0;
7
+ const events_1 = __importDefault(require("events"));
8
+ const error_1 = __importDefault(require("../error"));
9
+ const logger_1 = require("./logger");
10
+ class CatalystEventEmitter extends events_1.default {
11
+ constructor() {
12
+ super(...arguments);
13
+ this.listenerMap = new WeakMap();
14
+ }
15
+ on(event, listener) {
16
+ const wrappedListener = (...args) => {
17
+ try {
18
+ listener(...args);
19
+ }
20
+ catch (er) {
21
+ throw error_1.default.getErrorInstance(er, {
22
+ message: 'Error when processing the <on> listener of ServerEvent: ' + event,
23
+ skipHelp: true
24
+ });
25
+ }
26
+ };
27
+ this.listenerMap.set(listener, wrappedListener);
28
+ super.on(event, wrappedListener);
29
+ return this;
30
+ }
31
+ once(event, listener) {
32
+ const wrappedListener = (...args) => {
33
+ try {
34
+ listener(...args);
35
+ }
36
+ catch (er) {
37
+ throw error_1.default.getErrorInstance(er, {
38
+ message: 'Error when processing the <once> listener of ServerEvent: ' + event,
39
+ skipHelp: true
40
+ });
41
+ }
42
+ this.listenerMap.delete(listener);
43
+ };
44
+ this.listenerMap.set(listener, wrappedListener);
45
+ super.once(event, wrappedListener);
46
+ return this;
47
+ }
48
+ removeListener(event, listener) {
49
+ const wrappedListener = this.listenerMap.get(listener);
50
+ if (wrappedListener) {
51
+ super.removeListener(event, wrappedListener);
52
+ this.listenerMap.delete(listener);
53
+ }
54
+ return this;
55
+ }
56
+ off(event, listener) {
57
+ return this.removeListener(event, listener);
58
+ }
59
+ emit(...args) {
60
+ const [event] = args;
61
+ if (event === 'error' && this.listenerCount('error') === 0) {
62
+ (0, logger_1.debug)('Unable to emit "error" event as no listeners are attached');
63
+ return false;
64
+ }
65
+ return super.emit(...args);
66
+ }
67
+ }
68
+ exports.CatalystEventEmitter = CatalystEventEmitter;
@@ -15,13 +15,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
15
15
  }) : function(o, v) {
16
16
  o["default"] = v;
17
17
  });
18
- var __importStar = (this && this.__importStar) || function (mod) {
19
- if (mod && mod.__esModule) return mod;
20
- var result = {};
21
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
- __setModuleDefault(result, mod);
23
- return result;
24
- };
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
25
35
  Object.defineProperty(exports, "__esModule", { value: true });
26
36
  exports.ASYNC = exports.SYNC = void 0;
27
37
  const ASYNC = __importStar(require("./lib/async"));
@@ -1,7 +1,3 @@
1
- /// <reference types="node" />
2
- /// <reference types="node" />
3
- /// <reference types="node" />
4
- /// <reference types="node" />
5
1
  import fs, { CopyFilterAsync, Stats } from 'fs-extra';
6
2
  type OutputType = 'buffer' | 'utf8' | undefined;
7
3
  type OutputByType<T> = T extends 'buffer' ? Buffer : string;
@@ -12,7 +12,30 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
12
12
  return (mod && mod.__esModule) ? mod : { "default": mod };
13
13
  };
14
14
  Object.defineProperty(exports, "__esModule", { value: true });
15
- exports.isDirEmpty = exports.readStreamAsJSON = exports.chmod = exports.writeJSONFile = exports.readJSONFile = exports.emptyDir = exports.findAndReplace = exports.rename = exports.copyDir = exports.copyFiles = exports.copyFile = exports.deleteDir = exports.deleteFile = exports.ensureDir = exports.ensureFile = exports.walk = exports.dirList = exports.writeFile = exports.tempFile = exports.readFile = exports.getFileDetails = exports.fileExists = exports.dirExists = exports.isPathExists = void 0;
15
+ exports.findAndReplace = void 0;
16
+ exports.isPathExists = isPathExists;
17
+ exports.dirExists = dirExists;
18
+ exports.fileExists = fileExists;
19
+ exports.getFileDetails = getFileDetails;
20
+ exports.readFile = readFile;
21
+ exports.tempFile = tempFile;
22
+ exports.writeFile = writeFile;
23
+ exports.dirList = dirList;
24
+ exports.walk = walk;
25
+ exports.ensureFile = ensureFile;
26
+ exports.ensureDir = ensureDir;
27
+ exports.deleteFile = deleteFile;
28
+ exports.deleteDir = deleteDir;
29
+ exports.copyFile = copyFile;
30
+ exports.copyFiles = copyFiles;
31
+ exports.copyDir = copyDir;
32
+ exports.rename = rename;
33
+ exports.emptyDir = emptyDir;
34
+ exports.readJSONFile = readJSONFile;
35
+ exports.writeJSONFile = writeJSONFile;
36
+ exports.chmod = chmod;
37
+ exports.readStreamAsJSON = readStreamAsJSON;
38
+ exports.isDirEmpty = isDirEmpty;
16
39
  const fs_extra_1 = __importDefault(require("fs-extra"));
17
40
  const minimatch_1 = __importDefault(require("minimatch"));
18
41
  const os_1 = __importDefault(require("os"));
@@ -25,27 +48,23 @@ function isPathExists(path) {
25
48
  return stats && true;
26
49
  });
27
50
  }
28
- exports.isPathExists = isPathExists;
29
51
  function dirExists(pth) {
30
52
  return __awaiter(this, void 0, void 0, function* () {
31
53
  const stats = yield fs_extra_1.default.stat((0, utils_js_1.untildify)(pth)).catch(() => false);
32
54
  return stats && stats.isDirectory();
33
55
  });
34
56
  }
35
- exports.dirExists = dirExists;
36
57
  function fileExists(pth) {
37
58
  return __awaiter(this, void 0, void 0, function* () {
38
59
  const stats = yield fs_extra_1.default.stat((0, utils_js_1.untildify)(pth)).catch(() => false);
39
60
  return stats && stats.isFile();
40
61
  });
41
62
  }
42
- exports.fileExists = fileExists;
43
63
  function getFileDetails(pth) {
44
64
  return __awaiter(this, void 0, void 0, function* () {
45
65
  return fs_extra_1.default.stat((0, utils_js_1.untildify)(pth));
46
66
  });
47
67
  }
48
- exports.getFileDetails = getFileDetails;
49
68
  function readFile(pth, type) {
50
69
  return __awaiter(this, void 0, void 0, function* () {
51
70
  if (!(yield fileExists(pth))) {
@@ -58,22 +77,19 @@ function readFile(pth, type) {
58
77
  : fs_extra_1.default.readFile(pth, 'utf8'));
59
78
  });
60
79
  }
61
- exports.readFile = readFile;
62
- function tempFile(name = Date.now().toString(), content) {
63
- return __awaiter(this, void 0, void 0, function* () {
80
+ function tempFile() {
81
+ return __awaiter(this, arguments, void 0, function* (name = Date.now().toString(), content) {
64
82
  const tempDir = path_1.default.join(os_1.default.tmpdir(), '.catalyst');
65
83
  const tempFilePth = path_1.default.join(tempDir, name);
66
84
  content === undefined ? yield ensureFile(tempFilePth) : yield writeFile(tempFilePth, content);
67
85
  return tempFilePth;
68
86
  });
69
87
  }
70
- exports.tempFile = tempFile;
71
- function writeFile(pth, content, encoding = 'utf8') {
72
- return __awaiter(this, void 0, void 0, function* () {
88
+ function writeFile(pth_1, content_1) {
89
+ return __awaiter(this, arguments, void 0, function* (pth, content, encoding = 'utf8') {
73
90
  return fs_extra_1.default.writeFile(pth, content, { encoding });
74
91
  });
75
92
  }
76
- exports.writeFile = writeFile;
77
93
  function dirList(dir) {
78
94
  return __awaiter(this, void 0, void 0, function* () {
79
95
  const files = yield fs_extra_1.default.readdir(dir);
@@ -88,13 +104,12 @@ function dirList(dir) {
88
104
  return entries.filter((entry) => entry !== undefined);
89
105
  });
90
106
  }
91
- exports.dirList = dirList;
92
- function walk(dir, { filter = {
93
- exclude: [],
94
- excludeDir: true,
95
- ignoreFiles: false
96
- }, depth = -1, includeDirPaths = false } = {}) {
97
- return __awaiter(this, void 0, void 0, function* () {
107
+ function walk(dir_1) {
108
+ return __awaiter(this, arguments, void 0, function* (dir, { filter = {
109
+ exclude: [],
110
+ excludeDir: true,
111
+ ignoreFiles: false
112
+ }, depth = -1, includeDirPaths = false } = {}) {
98
113
  const stats = yield fs_extra_1.default.lstat(dir);
99
114
  if (depth === 0) {
100
115
  return includeDirPaths ? [{ path: dir, stats }] : [];
@@ -130,9 +145,8 @@ function walk(dir, { filter = {
130
145
  return folderContents.reduce((all, folderContent) => all.concat(folderContent), includeDirPaths ? [{ path: dir, stats }] : []);
131
146
  });
132
147
  }
133
- exports.walk = walk;
134
- function ensureFile(filePath, cleanFile = false) {
135
- return __awaiter(this, void 0, void 0, function* () {
148
+ function ensureFile(filePath_1) {
149
+ return __awaiter(this, arguments, void 0, function* (filePath, cleanFile = false) {
136
150
  const isFile = yield fileExists(filePath);
137
151
  if (!isFile) {
138
152
  return fs_extra_1.default.ensureFile(filePath);
@@ -143,27 +157,23 @@ function ensureFile(filePath, cleanFile = false) {
143
157
  return;
144
158
  });
145
159
  }
146
- exports.ensureFile = ensureFile;
147
160
  function ensureDir(pth) {
148
161
  return __awaiter(this, void 0, void 0, function* () {
149
162
  return fs_extra_1.default.ensureDir(pth);
150
163
  });
151
164
  }
152
- exports.ensureDir = ensureDir;
153
165
  function deleteFile(filePath) {
154
166
  return __awaiter(this, void 0, void 0, function* () {
155
167
  return fs_extra_1.default.remove(filePath);
156
168
  });
157
169
  }
158
- exports.deleteFile = deleteFile;
159
170
  function deleteDir(dir) {
160
171
  return __awaiter(this, void 0, void 0, function* () {
161
172
  return fs_extra_1.default.remove(dir);
162
173
  });
163
174
  }
164
- exports.deleteDir = deleteDir;
165
- function copyFile(src, dest, overwrite = true) {
166
- return __awaiter(this, void 0, void 0, function* () {
175
+ function copyFile(src_1, dest_1) {
176
+ return __awaiter(this, arguments, void 0, function* (src, dest, overwrite = true) {
167
177
  yield ensureDir(path_1.default.dirname(dest));
168
178
  return fs_extra_1.default.copy(src, dest, {
169
179
  dereference: true,
@@ -173,7 +183,6 @@ function copyFile(src, dest, overwrite = true) {
173
183
  });
174
184
  });
175
185
  }
176
- exports.copyFile = copyFile;
177
186
  function copyFiles(src, dest) {
178
187
  return __awaiter(this, void 0, void 0, function* () {
179
188
  return Promise.all(src.map((filePath) => {
@@ -182,15 +191,13 @@ function copyFiles(src, dest) {
182
191
  }));
183
192
  });
184
193
  }
185
- exports.copyFiles = copyFiles;
186
- function copyDir(srcDir, destDir, { filter = () => __awaiter(this, void 0, void 0, function* () { return true; }) } = {}) {
187
- return __awaiter(this, void 0, void 0, function* () {
194
+ function copyDir(srcDir_1, destDir_1) {
195
+ return __awaiter(this, arguments, void 0, function* (srcDir, destDir, { filter = () => __awaiter(this, void 0, void 0, function* () { return true; }) } = {}) {
188
196
  return fs_extra_1.default.copy(srcDir, destDir, { filter });
189
197
  });
190
198
  }
191
- exports.copyDir = copyDir;
192
- function rename(pth, modifier = (baseName) => baseName) {
193
- return __awaiter(this, void 0, void 0, function* () {
199
+ function rename(pth_1) {
200
+ return __awaiter(this, arguments, void 0, function* (pth, modifier = (baseName) => baseName) {
194
201
  if (Array.isArray(pth)) {
195
202
  yield Promise.all(pth.map((el) => rename(el, modifier)));
196
203
  return;
@@ -200,7 +207,6 @@ function rename(pth, modifier = (baseName) => baseName) {
200
207
  return fs_extra_1.default.rename(pth, modifiedName);
201
208
  });
202
209
  }
203
- exports.rename = rename;
204
210
  const findAndReplace = (pth) => (templates, finalWords) => __awaiter(void 0, void 0, void 0, function* () {
205
211
  if (Array.isArray(pth)) {
206
212
  yield Promise.all(pth.map((el) => (0, exports.findAndReplace)(el)(templates, finalWords)));
@@ -229,7 +235,6 @@ function emptyDir(dir) {
229
235
  return fs_extra_1.default.emptyDir(dir);
230
236
  });
231
237
  }
232
- exports.emptyDir = emptyDir;
233
238
  function readJSONFile(pth, opts) {
234
239
  return __awaiter(this, void 0, void 0, function* () {
235
240
  if (opts && opts.checkpath && !(yield fileExists(pth))) {
@@ -238,16 +243,14 @@ function readJSONFile(pth, opts) {
238
243
  return fs_extra_1.default.readJson(pth, opts);
239
244
  });
240
245
  }
241
- exports.readJSONFile = readJSONFile;
242
- function writeJSONFile(pth, object, opts = { spaces: '\t' }) {
243
- return __awaiter(this, void 0, void 0, function* () {
246
+ function writeJSONFile(pth_1, object_1) {
247
+ return __awaiter(this, arguments, void 0, function* (pth, object, opts = { spaces: '\t' }) {
244
248
  yield ensureFile(pth, true);
245
249
  return fs_extra_1.default.writeJson(pth, object, opts);
246
250
  });
247
251
  }
248
- exports.writeJSONFile = writeJSONFile;
249
- function chmod(path, mode, { checkPath = true, recursive = false } = {}) {
250
- return __awaiter(this, void 0, void 0, function* () {
252
+ function chmod(path_2, mode_1) {
253
+ return __awaiter(this, arguments, void 0, function* (path, mode, { checkPath = true, recursive = false } = {}) {
251
254
  if (checkPath && !(yield isPathExists(path))) {
252
255
  return Promise.reject('Path does not exists');
253
256
  }
@@ -259,7 +262,6 @@ function chmod(path, mode, { checkPath = true, recursive = false } = {}) {
259
262
  return fs_extra_1.default.chmod(path, mode);
260
263
  });
261
264
  }
262
- exports.chmod = chmod;
263
265
  function readStreamAsJSON(stream) {
264
266
  return __awaiter(this, void 0, void 0, function* () {
265
267
  return new Promise((resolve, reject) => {
@@ -281,11 +283,9 @@ function readStreamAsJSON(stream) {
281
283
  });
282
284
  });
283
285
  }
284
- exports.readStreamAsJSON = readStreamAsJSON;
285
286
  function isDirEmpty(pth) {
286
287
  return __awaiter(this, void 0, void 0, function* () {
287
288
  const files = yield fs_extra_1.default.readdir(pth);
288
289
  return files.length === 0;
289
290
  });
290
291
  }
291
- exports.isDirEmpty = isDirEmpty;
@@ -1,6 +1,3 @@
1
- /// <reference types="node" />
2
- /// <reference types="node" />
3
- /// <reference types="node" />
4
1
  import fs, { CopyFilterSync } from 'fs-extra';
5
2
  export declare function getWriteStream(pth: string, mode?: number): fs.WriteStream;
6
3
  export declare function getReadStream(pth: string): fs.ReadStream;
@@ -18,6 +15,7 @@ export declare function writeFile(pth: string, data: Buffer | Uint8Array | strin
18
15
  export declare function appendFile(pth: string, data: Buffer | Uint8Array | string, encoding?: BufferEncoding): void;
19
16
  export declare function modifyFileName(pth: string | Array<string>, modifier: (fullPth: string, extension: string) => string): Array<string>;
20
17
  export declare function renameFile(pth: string | Array<string>, modifier: (fullPth: string, extension: string) => string): Array<void>;
18
+ export declare function renameDir(from: string, to: string): boolean;
21
19
  export declare function isPathOutside(from: string, to: string): boolean;
22
20
  export declare function isPathInside(from: string, to: string): boolean;
23
21
  export declare function deleteDir(dir: string): void;
@@ -3,7 +3,36 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.isDirEmpty = exports.readPackageJson = exports.writeJSONFile = exports.readJSONFile = exports.emptyDir = exports.copyDir = exports.copyFiles = exports.copyFile = exports.deleteTempDir = exports.tempFile = exports.deleteDir = exports.isPathInside = exports.isPathOutside = exports.renameFile = exports.modifyFileName = exports.appendFile = exports.writeFile = exports.ensureFile = exports.ensureDir = exports.readFile = exports.deleteFile = exports.getAllFiles = exports.getAllDirs = exports.dirExists = exports.pathExists = exports.fileExists = exports.readSymLink = exports.getReadStream = exports.getWriteStream = void 0;
6
+ exports.getWriteStream = getWriteStream;
7
+ exports.getReadStream = getReadStream;
8
+ exports.readSymLink = readSymLink;
9
+ exports.fileExists = fileExists;
10
+ exports.pathExists = pathExists;
11
+ exports.dirExists = dirExists;
12
+ exports.getAllDirs = getAllDirs;
13
+ exports.getAllFiles = getAllFiles;
14
+ exports.deleteFile = deleteFile;
15
+ exports.readFile = readFile;
16
+ exports.ensureDir = ensureDir;
17
+ exports.ensureFile = ensureFile;
18
+ exports.writeFile = writeFile;
19
+ exports.appendFile = appendFile;
20
+ exports.modifyFileName = modifyFileName;
21
+ exports.renameFile = renameFile;
22
+ exports.renameDir = renameDir;
23
+ exports.isPathOutside = isPathOutside;
24
+ exports.isPathInside = isPathInside;
25
+ exports.deleteDir = deleteDir;
26
+ exports.tempFile = tempFile;
27
+ exports.deleteTempDir = deleteTempDir;
28
+ exports.copyFile = copyFile;
29
+ exports.copyFiles = copyFiles;
30
+ exports.copyDir = copyDir;
31
+ exports.emptyDir = emptyDir;
32
+ exports.readJSONFile = readJSONFile;
33
+ exports.writeJSONFile = writeJSONFile;
34
+ exports.readPackageJson = readPackageJson;
35
+ exports.isDirEmpty = isDirEmpty;
7
36
  const fs_extra_1 = __importDefault(require("fs-extra"));
8
37
  const os_1 = __importDefault(require("os"));
9
38
  const path_1 = require("path");
@@ -11,15 +40,12 @@ const utils_1 = require("../utils");
11
40
  function getWriteStream(pth, mode) {
12
41
  return fs_extra_1.default.createWriteStream(pth, { mode });
13
42
  }
14
- exports.getWriteStream = getWriteStream;
15
43
  function getReadStream(pth) {
16
44
  return fs_extra_1.default.createReadStream(pth);
17
45
  }
18
- exports.getReadStream = getReadStream;
19
46
  function readSymLink(pth) {
20
47
  return fs_extra_1.default.readlinkSync(pth);
21
48
  }
22
- exports.readSymLink = readSymLink;
23
49
  function fileExists(pth) {
24
50
  try {
25
51
  const stats = fs_extra_1.default.statSync(pth);
@@ -29,7 +55,6 @@ function fileExists(pth) {
29
55
  return false;
30
56
  }
31
57
  }
32
- exports.fileExists = fileExists;
33
58
  function pathExists(pth) {
34
59
  try {
35
60
  const stats = fs_extra_1.default.statSync((0, utils_1.untildify)(pth));
@@ -39,7 +64,6 @@ function pathExists(pth) {
39
64
  return false;
40
65
  }
41
66
  }
42
- exports.pathExists = pathExists;
43
67
  function dirExists(pth) {
44
68
  try {
45
69
  const stats = fs_extra_1.default.statSync(pth);
@@ -49,7 +73,6 @@ function dirExists(pth) {
49
73
  return false;
50
74
  }
51
75
  }
52
- exports.dirExists = dirExists;
53
76
  function getAllDirs(srcPath) {
54
77
  const directories = fs_extra_1.default
55
78
  .readdirSync(srcPath)
@@ -61,7 +84,6 @@ function getAllDirs(srcPath) {
61
84
  });
62
85
  return directories;
63
86
  }
64
- exports.getAllDirs = getAllDirs;
65
87
  function getAllFiles(srcPath) {
66
88
  const files = fs_extra_1.default
67
89
  .readdirSync(srcPath)
@@ -73,22 +95,18 @@ function getAllFiles(srcPath) {
73
95
  });
74
96
  return files;
75
97
  }
76
- exports.getAllFiles = getAllFiles;
77
98
  function deleteFile(pth) {
78
99
  return fs_extra_1.default.removeSync(pth);
79
100
  }
80
- exports.deleteFile = deleteFile;
81
101
  function readFile(pth, encoding = 'utf8') {
82
102
  if (fileExists(pth)) {
83
103
  return fs_extra_1.default.readFileSync(pth, encoding);
84
104
  }
85
105
  return undefined;
86
106
  }
87
- exports.readFile = readFile;
88
107
  function ensureDir(dir) {
89
108
  return fs_extra_1.default.ensureDirSync(dir);
90
109
  }
91
- exports.ensureDir = ensureDir;
92
110
  function ensureFile(filePath, cleanFile = false) {
93
111
  const isFile = fileExists(filePath);
94
112
  if (!isFile) {
@@ -99,15 +117,12 @@ function ensureFile(filePath, cleanFile = false) {
99
117
  }
100
118
  return;
101
119
  }
102
- exports.ensureFile = ensureFile;
103
120
  function writeFile(pth, data, encoding = 'utf8') {
104
121
  return fs_extra_1.default.writeFileSync(pth, data, { encoding });
105
122
  }
106
- exports.writeFile = writeFile;
107
123
  function appendFile(pth, data, encoding = 'utf8') {
108
124
  return fs_extra_1.default.appendFileSync(pth, data, { encoding });
109
125
  }
110
- exports.appendFile = appendFile;
111
126
  function modifyFileName(pth, modifier) {
112
127
  pth = Array.isArray(pth) ? pth : [pth];
113
128
  return pth.map((el) => {
@@ -115,71 +130,68 @@ function modifyFileName(pth, modifier) {
115
130
  return (0, path_1.join)((0, path_1.dirname)(el), modifier((0, path_1.basename)(el, ext), ext));
116
131
  });
117
132
  }
118
- exports.modifyFileName = modifyFileName;
119
133
  function renameFile(pth, modifier) {
120
134
  pth = Array.isArray(pth) ? pth : [pth];
121
135
  return pth.map((el) => fs_extra_1.default.renameSync(el, modifyFileName(el, modifier)[0]));
122
136
  }
123
- exports.renameFile = renameFile;
137
+ function renameDir(from, to) {
138
+ if (isDirEmpty(from)) {
139
+ return false;
140
+ }
141
+ if ((0, path_1.resolve)(from) === (0, path_1.resolve)(to)) {
142
+ return true;
143
+ }
144
+ fs_extra_1.default.renameSync(from, to);
145
+ return true;
146
+ }
124
147
  function isPathOutside(from, to) {
125
148
  return !isPathInside(from, to);
126
149
  }
127
- exports.isPathOutside = isPathOutside;
128
150
  function isPathInside(from, to) {
129
151
  const relativePth = (0, path_1.relative)(from, to);
130
152
  return !!((from === to || relativePth) &&
131
153
  !relativePth.startsWith('..') &&
132
154
  !(0, path_1.isAbsolute)(relativePth));
133
155
  }
134
- exports.isPathInside = isPathInside;
135
156
  function deleteDir(dir) {
136
157
  return fs_extra_1.default.removeSync(dir);
137
158
  }
138
- exports.deleteDir = deleteDir;
139
159
  function tempFile(name = Date.now().toString()) {
140
160
  const tempDir = (0, path_1.join)(os_1.default.tmpdir(), '.catalyst');
141
161
  const tempFilePth = (0, path_1.join)(tempDir, name);
142
162
  fs_extra_1.default.ensureFileSync(tempFilePth);
143
163
  return tempFilePth;
144
164
  }
145
- exports.tempFile = tempFile;
146
165
  function deleteTempDir() {
147
166
  const dir = (0, path_1.join)(os_1.default.tmpdir(), '.catalyst');
148
167
  return deleteDir(dir);
149
168
  }
150
- exports.deleteTempDir = deleteTempDir;
151
169
  function copyFile(src, dest) {
152
170
  ensureDir((0, path_1.dirname)(dest));
153
171
  return fs_extra_1.default.copyFileSync(src, dest);
154
172
  }
155
- exports.copyFile = copyFile;
156
173
  function copyFiles(src, dest) {
157
174
  src.forEach((srcPath) => {
158
175
  const file = (0, path_1.basename)(srcPath);
159
176
  copyFile(srcPath, (0, path_1.join)(dest, file));
160
177
  });
161
178
  }
162
- exports.copyFiles = copyFiles;
163
179
  function copyDir(srcDir, destDir, { filter = () => true, overwrite = true, errorOnExist = false } = {}) {
164
180
  return fs_extra_1.default.copySync(srcDir, destDir, { filter, overwrite, errorOnExist });
165
181
  }
166
- exports.copyDir = copyDir;
167
182
  function emptyDir(dir) {
168
183
  return fs_extra_1.default.emptyDirSync(dir);
169
184
  }
170
- exports.emptyDir = emptyDir;
171
185
  function readJSONFile(pth, opts) {
172
186
  if (opts && opts.checkpath && !fileExists(pth)) {
173
187
  return undefined;
174
188
  }
175
189
  return fs_extra_1.default.readJsonSync(pth, opts);
176
190
  }
177
- exports.readJSONFile = readJSONFile;
178
191
  function writeJSONFile(pth, object, opts) {
179
192
  ensureFile(pth, true);
180
193
  return fs_extra_1.default.writeJsonSync(pth, object, opts);
181
194
  }
182
- exports.writeJSONFile = writeJSONFile;
183
195
  function readPackageJson() {
184
196
  const pkg = readJSONFile((0, path_1.join)(__dirname, '../../../../package.json'), {
185
197
  checkpath: true,
@@ -187,9 +199,7 @@ function readPackageJson() {
187
199
  });
188
200
  return pkg;
189
201
  }
190
- exports.readPackageJson = readPackageJson;
191
202
  function isDirEmpty(pth) {
192
203
  const files = fs_extra_1.default.readdirSync(pth);
193
204
  return files.length === 0;
194
205
  }
195
- exports.isDirEmpty = isDirEmpty;
@@ -17,14 +17,22 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
17
17
  return (mod && mod.__esModule) ? mod : { "default": mod };
18
18
  };
19
19
  Object.defineProperty(exports, "__esModule", { value: true });
20
- exports.labeled = exports.local = exports.error = exports.warning = exports.message = exports.success = exports.debug = exports.info = exports.log = void 0;
20
+ exports.local = void 0;
21
+ exports.log = log;
22
+ exports.info = info;
23
+ exports.debug = debug;
24
+ exports.success = success;
25
+ exports.message = message;
26
+ exports.warning = warning;
27
+ exports.error = error;
28
+ exports.labeled = labeled;
21
29
  const ansi_colors_1 = __importDefault(require("ansi-colors"));
30
+ const util_1 = require("util");
31
+ const os_1 = require("os");
22
32
  const utils_1 = require("./utils");
23
33
  const winston_1 = __importDefault(require("./winston"));
24
- const util_1 = require("util");
25
34
  const env_1 = require("../env");
26
- const os_1 = require("os");
27
- const logStream = env_1.isVsCode && utils_1.LogStreamFactory.getStream();
35
+ const logStream = env_1.isExtension && utils_1.LogStreamFactory.getStream();
28
36
  function _log(level, message, ignoreHttpLogger = false) {
29
37
  if (logStream && logStream.writable && level !== 'debug') {
30
38
  logStream.write(message.endsWith(os_1.EOL) ? message : message + os_1.EOL);
@@ -34,35 +42,28 @@ function _log(level, message, ignoreHttpLogger = false) {
34
42
  function log(level, message, ignoreHttpLogger) {
35
43
  _log(level, message, ignoreHttpLogger);
36
44
  }
37
- exports.log = log;
38
45
  function info(msg = '', ...params) {
39
46
  _log('info', (0, util_1.format)(msg, ...params));
40
47
  }
41
- exports.info = info;
42
48
  function debug(msg = '', ...params) {
43
49
  _log('debug', (0, util_1.format)(msg, ...params));
44
50
  }
45
- exports.debug = debug;
46
51
  function success(msg, level = 'info', label = '', padLeft = '') {
47
52
  const postChar = label === '' ? '' : label + ': ';
48
53
  _log(level, padLeft + ansi_colors_1.default.green(utils_1.CHAR.success + ' ' + postChar) + msg);
49
54
  }
50
- exports.success = success;
51
55
  function message(msg, level = 'info', label = '', padLeft = '') {
52
56
  const postChar = label === '' ? '' : label + ': ';
53
57
  _log(level, padLeft + ansi_colors_1.default.cyan(utils_1.CHAR.info + ' ' + postChar) + msg);
54
58
  }
55
- exports.message = message;
56
59
  function warning(msg, level = 'warn', label = '', padLeft = '') {
57
60
  const postChar = label === '' ? '' : label + ': ';
58
61
  _log(level, padLeft + ansi_colors_1.default.yellow(utils_1.CHAR.warning + ' ' + postChar) + msg);
59
62
  }
60
- exports.warning = warning;
61
63
  function error(msg, level = 'error', label = '', padLeft = '') {
62
64
  const postChar = label === '' ? '' : label + ': ';
63
65
  _log(level, padLeft + ansi_colors_1.default.red(utils_1.CHAR.error + ' ' + postChar) + msg);
64
66
  }
65
- exports.error = error;
66
67
  exports.local = {
67
68
  info: (msg = '') => log('info', msg, true),
68
69
  warn: (msg = '') => log('warn', msg, true),
@@ -76,5 +77,4 @@ function labeled(label, line, padLeft) {
76
77
  ERROR: () => error(line, 'error', label, padLeft)
77
78
  };
78
79
  }
79
- exports.labeled = labeled;
80
80
  __exportStar(require("./utils"), exports);
@@ -1,7 +1,3 @@
1
- /// <reference types="node" />
2
- /// <reference types="node" />
3
- /// <reference types="node" />
4
- /// <reference types="node" />
5
1
  import { Direction } from 'readline';
6
2
  import { PassThrough } from 'stream';
7
3
  export declare const CHAR: {
@@ -58,7 +58,7 @@ class TTYPassThrough extends stream_1.PassThrough {
58
58
  exports.TTYPassThrough = TTYPassThrough;
59
59
  class LogStreamFactory {
60
60
  static getStream() {
61
- return __classPrivateFieldGet(LogStreamFactory, _a, "f", _LogStreamFactory_logStream);
61
+ return __classPrivateFieldGet(_a, _a, "f", _LogStreamFactory_logStream);
62
62
  }
63
63
  }
64
64
  exports.LogStreamFactory = LogStreamFactory;
@@ -3,7 +3,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.logger = exports.verbose = exports.transport = void 0;
6
+ exports.logger = exports.transport = void 0;
7
+ exports.verbose = verbose;
7
8
  const strip_ansi_1 = __importDefault(require("strip-ansi"));
8
9
  const winston_1 = require("winston");
9
10
  const config_store_1 = __importDefault(require("../config-store"));
@@ -76,7 +77,6 @@ function verbose(enable = true) {
76
77
  return info.message + '';
77
78
  });
78
79
  }
79
- exports.verbose = verbose;
80
80
  exports.logger = (0, winston_1.createLogger)({
81
81
  transports: [exports.transport.console],
82
82
  exitOnError: false