@capacitor/cli 4.7.3 → 5.0.0-alpha.2

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 (55) hide show
  1. package/assets/android-template.tar.gz +0 -0
  2. package/assets/capacitor-cordova-android-plugins.tar.gz +0 -0
  3. package/assets/capacitor-cordova-ios-plugins.tar.gz +0 -0
  4. package/assets/ios-template.tar.gz +0 -0
  5. package/dist/android/add.js +6 -6
  6. package/dist/android/build.js +12 -9
  7. package/dist/android/common.js +27 -29
  8. package/dist/android/doctor.js +24 -24
  9. package/dist/android/open.js +3 -3
  10. package/dist/android/run.js +9 -6
  11. package/dist/android/update.js +53 -53
  12. package/dist/common.js +23 -23
  13. package/dist/config.js +67 -61
  14. package/dist/cordova.js +75 -75
  15. package/dist/declarations.d.ts +17 -1
  16. package/dist/index.js +32 -29
  17. package/dist/ios/add.js +2 -2
  18. package/dist/ios/build.js +9 -9
  19. package/dist/ios/common.js +12 -12
  20. package/dist/ios/doctor.js +6 -6
  21. package/dist/ios/open.js +2 -2
  22. package/dist/ios/run.js +7 -7
  23. package/dist/ios/update.js +58 -62
  24. package/dist/ipc.js +6 -6
  25. package/dist/log.js +2 -2
  26. package/dist/plugin.js +11 -11
  27. package/dist/sysconfig.js +6 -6
  28. package/dist/tasks/add.js +27 -27
  29. package/dist/tasks/build.js +7 -6
  30. package/dist/tasks/copy.js +42 -42
  31. package/dist/tasks/create.js +1 -1
  32. package/dist/tasks/doctor.js +10 -10
  33. package/dist/tasks/init.js +30 -27
  34. package/dist/tasks/list.js +12 -12
  35. package/dist/tasks/migrate.js +189 -407
  36. package/dist/tasks/new-plugin.js +1 -1
  37. package/dist/tasks/open.js +10 -10
  38. package/dist/tasks/run.js +13 -13
  39. package/dist/tasks/serve.js +1 -1
  40. package/dist/tasks/sourcemaps.js +9 -9
  41. package/dist/tasks/sync.js +15 -15
  42. package/dist/tasks/telemetry.js +4 -4
  43. package/dist/tasks/update.js +14 -14
  44. package/dist/telemetry.js +8 -8
  45. package/dist/util/cli.js +2 -2
  46. package/dist/util/fs.js +7 -7
  47. package/dist/util/native-run.js +3 -3
  48. package/dist/util/node.js +2 -2
  49. package/dist/util/subprocess.js +1 -1
  50. package/dist/util/template.js +1 -1
  51. package/dist/util/term.js +1 -1
  52. package/dist/util/xml.js +1 -1
  53. package/dist/web/copy.js +4 -4
  54. package/package.json +12 -11
  55. package/CHANGELOG.md +0 -805
package/dist/config.js CHANGED
@@ -12,14 +12,14 @@ const fn_1 = require("./util/fn");
12
12
  const js_1 = require("./util/js");
13
13
  const node_1 = require("./util/node");
14
14
  const promise_1 = require("./util/promise");
15
- const debug = debug_1.default('capacitor:config');
15
+ const debug = (0, debug_1.default)('capacitor:config');
16
16
  exports.CONFIG_FILE_NAME_TS = 'capacitor.config.ts';
17
17
  exports.CONFIG_FILE_NAME_JS = 'capacitor.config.js';
18
18
  exports.CONFIG_FILE_NAME_JSON = 'capacitor.config.json';
19
19
  async function loadConfig() {
20
- var _a, _b, _c, _d, _e;
20
+ var _a, _b, _c, _d;
21
21
  const appRootDir = process.cwd();
22
- const cliRootDir = path_1.dirname(__dirname);
22
+ const cliRootDir = (0, path_1.dirname)(__dirname);
23
23
  const conf = await loadExtConfig(appRootDir);
24
24
  const appId = (_a = conf.extConfig.appId) !== null && _a !== void 0 ? _a : '';
25
25
  const appName = (_b = conf.extConfig.appName) !== null && _b !== void 0 ? _b : '';
@@ -35,13 +35,12 @@ async function loadConfig() {
35
35
  appId,
36
36
  appName,
37
37
  webDir,
38
- webDirAbs: path_1.resolve(appRootDir, webDir),
39
- package: (_d = (await fn_1.tryFn(utils_fs_1.readJSON, path_1.resolve(appRootDir, 'package.json')))) !== null && _d !== void 0 ? _d : {
38
+ webDirAbs: (0, path_1.resolve)(appRootDir, webDir),
39
+ package: (_d = (await (0, fn_1.tryFn)(utils_fs_1.readJSON, (0, path_1.resolve)(appRootDir, 'package.json')))) !== null && _d !== void 0 ? _d : {
40
40
  name: appName,
41
41
  version: '1.0.0',
42
42
  },
43
43
  ...conf,
44
- bundledWebRuntime: (_e = conf.extConfig.bundledWebRuntime) !== null && _e !== void 0 ? _e : false,
45
44
  },
46
45
  };
47
46
  debug('config: %O', config);
@@ -49,13 +48,13 @@ async function loadConfig() {
49
48
  }
50
49
  exports.loadConfig = loadConfig;
51
50
  async function writeConfig(extConfig, extConfigFilePath) {
52
- switch (path_1.extname(extConfigFilePath)) {
51
+ switch ((0, path_1.extname)(extConfigFilePath)) {
53
52
  case '.json': {
54
- await utils_fs_1.writeJSON(extConfigFilePath, extConfig, { spaces: 2 });
53
+ await (0, utils_fs_1.writeJSON)(extConfigFilePath, extConfig, { spaces: 2 });
55
54
  break;
56
55
  }
57
56
  case '.ts': {
58
- await utils_fs_1.writeFile(extConfigFilePath, formatConfigTS(extConfig));
57
+ await (0, utils_fs_1.writeFile)(extConfigFilePath, formatConfigTS(extConfig));
59
58
  break;
60
59
  }
61
60
  }
@@ -64,13 +63,13 @@ exports.writeConfig = writeConfig;
64
63
  async function loadExtConfigTS(rootDir, extConfigName, extConfigFilePath) {
65
64
  var _a, _b;
66
65
  try {
67
- const tsPath = node_1.resolveNode(rootDir, 'typescript');
66
+ const tsPath = (0, node_1.resolveNode)(rootDir, 'typescript');
68
67
  if (!tsPath) {
69
- errors_1.fatal('Could not find installation of TypeScript.\n' +
68
+ (0, errors_1.fatal)('Could not find installation of TypeScript.\n' +
70
69
  `To use ${colors_1.default.strong(extConfigName)} files, you must install TypeScript in your project, e.g. w/ ${colors_1.default.input('npm install -D typescript')}`);
71
70
  }
72
71
  const ts = require(tsPath); // eslint-disable-line @typescript-eslint/no-var-requires
73
- const extConfigObject = node_1.requireTS(ts, extConfigFilePath);
72
+ const extConfigObject = (0, node_1.requireTS)(ts, extConfigFilePath);
74
73
  const extConfig = (_a = extConfigObject.default) !== null && _a !== void 0 ? _a : extConfigObject;
75
74
  return {
76
75
  extConfigType: 'ts',
@@ -80,8 +79,8 @@ async function loadExtConfigTS(rootDir, extConfigName, extConfigFilePath) {
80
79
  };
81
80
  }
82
81
  catch (e) {
83
- if (!errors_1.isFatal(e)) {
84
- errors_1.fatal(`Parsing ${colors_1.default.strong(extConfigName)} failed.\n\n${(_b = e.stack) !== null && _b !== void 0 ? _b : e}`);
82
+ if (!(0, errors_1.isFatal)(e)) {
83
+ (0, errors_1.fatal)(`Parsing ${colors_1.default.strong(extConfigName)} failed.\n\n${(_b = e.stack) !== null && _b !== void 0 ? _b : e}`);
85
84
  }
86
85
  throw e;
87
86
  }
@@ -97,30 +96,30 @@ async function loadExtConfigJS(rootDir, extConfigName, extConfigFilePath) {
97
96
  };
98
97
  }
99
98
  catch (e) {
100
- errors_1.fatal(`Parsing ${colors_1.default.strong(extConfigName)} failed.\n\n${(_a = e.stack) !== null && _a !== void 0 ? _a : e}`);
99
+ (0, errors_1.fatal)(`Parsing ${colors_1.default.strong(extConfigName)} failed.\n\n${(_a = e.stack) !== null && _a !== void 0 ? _a : e}`);
101
100
  }
102
101
  }
103
102
  async function loadExtConfig(rootDir) {
104
103
  var _a;
105
- const extConfigFilePathTS = path_1.resolve(rootDir, exports.CONFIG_FILE_NAME_TS);
106
- if (await utils_fs_1.pathExists(extConfigFilePathTS)) {
104
+ const extConfigFilePathTS = (0, path_1.resolve)(rootDir, exports.CONFIG_FILE_NAME_TS);
105
+ if (await (0, utils_fs_1.pathExists)(extConfigFilePathTS)) {
107
106
  return loadExtConfigTS(rootDir, exports.CONFIG_FILE_NAME_TS, extConfigFilePathTS);
108
107
  }
109
- const extConfigFilePathJS = path_1.resolve(rootDir, exports.CONFIG_FILE_NAME_JS);
110
- if (await utils_fs_1.pathExists(extConfigFilePathJS)) {
108
+ const extConfigFilePathJS = (0, path_1.resolve)(rootDir, exports.CONFIG_FILE_NAME_JS);
109
+ if (await (0, utils_fs_1.pathExists)(extConfigFilePathJS)) {
111
110
  return loadExtConfigJS(rootDir, exports.CONFIG_FILE_NAME_JS, extConfigFilePathJS);
112
111
  }
113
- const extConfigFilePath = path_1.resolve(rootDir, exports.CONFIG_FILE_NAME_JSON);
112
+ const extConfigFilePath = (0, path_1.resolve)(rootDir, exports.CONFIG_FILE_NAME_JSON);
114
113
  return {
115
114
  extConfigType: 'json',
116
115
  extConfigName: exports.CONFIG_FILE_NAME_JSON,
117
116
  extConfigFilePath: extConfigFilePath,
118
- extConfig: (_a = (await fn_1.tryFn(utils_fs_1.readJSON, extConfigFilePath))) !== null && _a !== void 0 ? _a : {},
117
+ extConfig: (_a = (await (0, fn_1.tryFn)(utils_fs_1.readJSON, extConfigFilePath))) !== null && _a !== void 0 ? _a : {},
119
118
  };
120
119
  }
121
120
  async function loadCLIConfig(rootDir) {
122
121
  const assetsDir = 'assets';
123
- const assetsDirAbs = path_1.join(rootDir, assetsDir);
122
+ const assetsDirAbs = (0, path_1.join)(rootDir, assetsDir);
124
123
  const iosPlatformTemplateArchive = 'ios-template.tar.gz';
125
124
  const iosCordovaPluginsTemplateArchive = 'capacitor-cordova-ios-plugins.tar.gz';
126
125
  const androidPlatformTemplateArchive = 'android-template.tar.gz';
@@ -132,18 +131,18 @@ async function loadCLIConfig(rootDir) {
132
131
  assets: {
133
132
  ios: {
134
133
  platformTemplateArchive: iosPlatformTemplateArchive,
135
- platformTemplateArchiveAbs: path_1.resolve(assetsDirAbs, iosPlatformTemplateArchive),
134
+ platformTemplateArchiveAbs: (0, path_1.resolve)(assetsDirAbs, iosPlatformTemplateArchive),
136
135
  cordovaPluginsTemplateArchive: iosCordovaPluginsTemplateArchive,
137
- cordovaPluginsTemplateArchiveAbs: path_1.resolve(assetsDirAbs, iosCordovaPluginsTemplateArchive),
136
+ cordovaPluginsTemplateArchiveAbs: (0, path_1.resolve)(assetsDirAbs, iosCordovaPluginsTemplateArchive),
138
137
  },
139
138
  android: {
140
139
  platformTemplateArchive: androidPlatformTemplateArchive,
141
- platformTemplateArchiveAbs: path_1.resolve(assetsDirAbs, androidPlatformTemplateArchive),
140
+ platformTemplateArchiveAbs: (0, path_1.resolve)(assetsDirAbs, androidPlatformTemplateArchive),
142
141
  cordovaPluginsTemplateArchive: androidCordovaPluginsTemplateArchive,
143
- cordovaPluginsTemplateArchiveAbs: path_1.resolve(assetsDirAbs, androidCordovaPluginsTemplateArchive),
142
+ cordovaPluginsTemplateArchiveAbs: (0, path_1.resolve)(assetsDirAbs, androidCordovaPluginsTemplateArchive),
144
143
  },
145
144
  },
146
- package: await utils_fs_1.readJSON(path_1.resolve(rootDir, 'package.json')),
145
+ package: await (0, utils_fs_1.readJSON)((0, path_1.resolve)(rootDir, 'package.json')),
147
146
  os: determineOS(process.platform),
148
147
  };
149
148
  }
@@ -151,7 +150,7 @@ async function loadAndroidConfig(rootDir, extConfig, cliConfig) {
151
150
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
152
151
  const name = 'android';
153
152
  const platformDir = (_b = (_a = extConfig.android) === null || _a === void 0 ? void 0 : _a.path) !== null && _b !== void 0 ? _b : 'android';
154
- const platformDirAbs = path_1.resolve(rootDir, platformDir);
153
+ const platformDirAbs = (0, path_1.resolve)(rootDir, platformDir);
155
154
  const appDir = 'app';
156
155
  const srcDir = `${appDir}/src`;
157
156
  const srcMainDir = `${srcDir}/main`;
@@ -168,7 +167,7 @@ async function loadAndroidConfig(rootDir, extConfig, cliConfig) {
168
167
  const apkName = `app${flavorPrefix}-debug.apk`;
169
168
  const buildOutputDir = `${apkPath}/debug`;
170
169
  const cordovaPluginsDir = 'capacitor-cordova-android-plugins';
171
- const studioPath = promise_1.lazy(() => determineAndroidStudioPath(cliConfig.os));
170
+ const studioPath = (0, promise_1.lazy)(() => determineAndroidStudioPath(cliConfig.os));
172
171
  const buildOptions = {
173
172
  keystorePath: (_h = (_g = extConfig.android) === null || _g === void 0 ? void 0 : _g.buildOptions) === null || _h === void 0 ? void 0 : _h.keystorePath,
174
173
  keystorePassword: (_k = (_j = extConfig.android) === null || _j === void 0 ? void 0 : _j.buildOptions) === null || _k === void 0 ? void 0 : _k.keystorePassword,
@@ -183,22 +182,22 @@ async function loadAndroidConfig(rootDir, extConfig, cliConfig) {
183
182
  platformDir,
184
183
  platformDirAbs,
185
184
  cordovaPluginsDir,
186
- cordovaPluginsDirAbs: path_1.resolve(platformDirAbs, cordovaPluginsDir),
185
+ cordovaPluginsDirAbs: (0, path_1.resolve)(platformDirAbs, cordovaPluginsDir),
187
186
  appDir,
188
- appDirAbs: path_1.resolve(platformDirAbs, appDir),
187
+ appDirAbs: (0, path_1.resolve)(platformDirAbs, appDir),
189
188
  srcDir,
190
- srcDirAbs: path_1.resolve(platformDirAbs, srcDir),
189
+ srcDirAbs: (0, path_1.resolve)(platformDirAbs, srcDir),
191
190
  srcMainDir,
192
- srcMainDirAbs: path_1.resolve(platformDirAbs, srcMainDir),
191
+ srcMainDirAbs: (0, path_1.resolve)(platformDirAbs, srcMainDir),
193
192
  assetsDir,
194
- assetsDirAbs: path_1.resolve(platformDirAbs, assetsDir),
193
+ assetsDirAbs: (0, path_1.resolve)(platformDirAbs, assetsDir),
195
194
  webDir,
196
- webDirAbs: path_1.resolve(platformDirAbs, webDir),
195
+ webDirAbs: (0, path_1.resolve)(platformDirAbs, webDir),
197
196
  resDir,
198
- resDirAbs: path_1.resolve(platformDirAbs, resDir),
197
+ resDirAbs: (0, path_1.resolve)(platformDirAbs, resDir),
199
198
  apkName,
200
199
  buildOutputDir,
201
- buildOutputDirAbs: path_1.resolve(platformDirAbs, buildOutputDir),
200
+ buildOutputDirAbs: (0, path_1.resolve)(platformDirAbs, buildOutputDir),
202
201
  flavor,
203
202
  buildOptions,
204
203
  };
@@ -208,16 +207,16 @@ async function loadIOSConfig(rootDir, extConfig) {
208
207
  const name = 'ios';
209
208
  const podPath = determineCocoapodPath();
210
209
  const platformDir = (_b = (_a = extConfig.ios) === null || _a === void 0 ? void 0 : _a.path) !== null && _b !== void 0 ? _b : 'ios';
211
- const platformDirAbs = path_1.resolve(rootDir, platformDir);
210
+ const platformDirAbs = (0, path_1.resolve)(rootDir, platformDir);
212
211
  const scheme = (_d = (_c = extConfig.ios) === null || _c === void 0 ? void 0 : _c.scheme) !== null && _d !== void 0 ? _d : 'App';
213
212
  const nativeProjectDir = 'App';
214
- const nativeProjectDirAbs = path_1.resolve(platformDirAbs, nativeProjectDir);
213
+ const nativeProjectDirAbs = (0, path_1.resolve)(platformDirAbs, nativeProjectDir);
215
214
  const nativeTargetDir = `${nativeProjectDir}/App`;
216
- const nativeTargetDirAbs = path_1.resolve(platformDirAbs, nativeTargetDir);
215
+ const nativeTargetDirAbs = (0, path_1.resolve)(platformDirAbs, nativeTargetDir);
217
216
  const nativeXcodeProjDir = `${nativeProjectDir}/App.xcodeproj`;
218
- const nativeXcodeProjDirAbs = path_1.resolve(platformDirAbs, nativeXcodeProjDir);
219
- const nativeXcodeWorkspaceDirAbs = promise_1.lazy(() => determineXcodeWorkspaceDirAbs(nativeProjectDirAbs));
220
- const webDirAbs = promise_1.lazy(() => determineIOSWebDirAbs(nativeProjectDirAbs, nativeTargetDirAbs, nativeXcodeProjDirAbs));
217
+ const nativeXcodeProjDirAbs = (0, path_1.resolve)(platformDirAbs, nativeXcodeProjDir);
218
+ const nativeXcodeWorkspaceDirAbs = (0, promise_1.lazy)(() => determineXcodeWorkspaceDirAbs(nativeProjectDirAbs));
219
+ const webDirAbs = (0, promise_1.lazy)(() => determineIOSWebDirAbs(nativeProjectDirAbs, nativeTargetDirAbs, nativeXcodeProjDirAbs));
221
220
  const cordovaPluginsDir = 'capacitor-cordova-ios-plugins';
222
221
  return {
223
222
  name,
@@ -226,23 +225,23 @@ async function loadIOSConfig(rootDir, extConfig) {
226
225
  platformDirAbs,
227
226
  scheme,
228
227
  cordovaPluginsDir,
229
- cordovaPluginsDirAbs: path_1.resolve(platformDirAbs, cordovaPluginsDir),
228
+ cordovaPluginsDirAbs: (0, path_1.resolve)(platformDirAbs, cordovaPluginsDir),
230
229
  nativeProjectDir,
231
230
  nativeProjectDirAbs,
232
231
  nativeTargetDir,
233
232
  nativeTargetDirAbs,
234
233
  nativeXcodeProjDir,
235
234
  nativeXcodeProjDirAbs,
236
- nativeXcodeWorkspaceDir: promise_1.lazy(async () => path_1.relative(platformDirAbs, await nativeXcodeWorkspaceDirAbs)),
235
+ nativeXcodeWorkspaceDir: (0, promise_1.lazy)(async () => (0, path_1.relative)(platformDirAbs, await nativeXcodeWorkspaceDirAbs)),
237
236
  nativeXcodeWorkspaceDirAbs,
238
- webDir: promise_1.lazy(async () => path_1.relative(platformDirAbs, await webDirAbs)),
237
+ webDir: (0, promise_1.lazy)(async () => (0, path_1.relative)(platformDirAbs, await webDirAbs)),
239
238
  webDirAbs,
240
239
  podPath,
241
240
  };
242
241
  }
243
242
  async function loadWebConfig(rootDir, webDir) {
244
243
  const platformDir = webDir;
245
- const platformDirAbs = path_1.resolve(rootDir, platformDir);
244
+ const platformDirAbs = (0, path_1.resolve)(rootDir, platformDir);
246
245
  return {
247
246
  name: 'web',
248
247
  platformDir,
@@ -252,46 +251,46 @@ async function loadWebConfig(rootDir, webDir) {
252
251
  function determineOS(os) {
253
252
  switch (os) {
254
253
  case 'darwin':
255
- return "mac" /* Mac */;
254
+ return "mac" /* OS.Mac */;
256
255
  case 'win32':
257
- return "windows" /* Windows */;
256
+ return "windows" /* OS.Windows */;
258
257
  case 'linux':
259
- return "linux" /* Linux */;
258
+ return "linux" /* OS.Linux */;
260
259
  }
261
- return "unknown" /* Unknown */;
260
+ return "unknown" /* OS.Unknown */;
262
261
  }
263
262
  async function determineXcodeWorkspaceDirAbs(nativeProjectDirAbs) {
264
- return path_1.resolve(nativeProjectDirAbs, 'App.xcworkspace');
263
+ return (0, path_1.resolve)(nativeProjectDirAbs, 'App.xcworkspace');
265
264
  }
266
265
  async function determineIOSWebDirAbs(nativeProjectDirAbs, nativeTargetDirAbs, nativeXcodeProjDirAbs) {
267
266
  const re = /path\s=\spublic[\s\S]+?sourceTree\s=\s([^;]+)/;
268
- const pbxprojPath = path_1.resolve(nativeXcodeProjDirAbs, 'project.pbxproj');
267
+ const pbxprojPath = (0, path_1.resolve)(nativeXcodeProjDirAbs, 'project.pbxproj');
269
268
  try {
270
- const pbxproj = await utils_fs_1.readFile(pbxprojPath, { encoding: 'utf8' });
269
+ const pbxproj = await (0, utils_fs_1.readFile)(pbxprojPath, { encoding: 'utf8' });
271
270
  const m = pbxproj.match(re);
272
271
  if (m && m[1] === 'SOURCE_ROOT') {
273
272
  log_1.logger.warn(`Using the iOS project root for the ${colors_1.default.strong('public')} directory is deprecated.\n` +
274
273
  `Please follow the Upgrade Guide to move ${colors_1.default.strong('public')} inside the iOS target directory: ${colors_1.default.strong('https://capacitorjs.com/docs/updating/3-0#move-public-into-the-ios-target-directory')}`);
275
- return path_1.resolve(nativeProjectDirAbs, 'public');
274
+ return (0, path_1.resolve)(nativeProjectDirAbs, 'public');
276
275
  }
277
276
  }
278
277
  catch (e) {
279
278
  // ignore
280
279
  }
281
- return path_1.resolve(nativeTargetDirAbs, 'public');
280
+ return (0, path_1.resolve)(nativeTargetDirAbs, 'public');
282
281
  }
283
282
  async function determineAndroidStudioPath(os) {
284
283
  if (process.env.CAPACITOR_ANDROID_STUDIO_PATH) {
285
284
  return process.env.CAPACITOR_ANDROID_STUDIO_PATH;
286
285
  }
287
286
  switch (os) {
288
- case "mac" /* Mac */:
287
+ case "mac" /* OS.Mac */:
289
288
  return '/Applications/Android Studio.app';
290
- case "windows" /* Windows */: {
289
+ case "windows" /* OS.Windows */: {
291
290
  const { runCommand } = await Promise.resolve().then(() => tslib_1.__importStar(require('./util/subprocess')));
292
291
  let p = 'C:\\Program Files\\Android\\Android Studio\\bin\\studio64.exe';
293
292
  try {
294
- if (!(await utils_fs_1.pathExists(p))) {
293
+ if (!(await (0, utils_fs_1.pathExists)(p))) {
295
294
  let commandResult = await runCommand('REG', [
296
295
  'QUERY',
297
296
  'HKEY_LOCAL_MACHINE\\SOFTWARE\\Android Studio',
@@ -311,7 +310,7 @@ async function determineAndroidStudioPath(os) {
311
310
  }
312
311
  return p;
313
312
  }
314
- case "linux" /* Linux */:
313
+ case "linux" /* OS.Linux */:
315
314
  return '/usr/local/android-studio/bin/studio.sh';
316
315
  }
317
316
  return '';
@@ -326,7 +325,7 @@ function formatConfigTS(extConfig) {
326
325
  // TODO: <reference> tags
327
326
  return `import { CapacitorConfig } from '@capacitor/cli';
328
327
 
329
- const config: CapacitorConfig = ${js_1.formatJSObject(extConfig)};
328
+ const config: CapacitorConfig = ${(0, js_1.formatJSObject)(extConfig)};
330
329
 
331
330
  export default config;\n`;
332
331
  }
@@ -338,5 +337,12 @@ function checkExternalConfig(config) {
338
337
  log_1.logger.warn(`The ${colors_1.default.strong('hideLogs')} configuration option has been deprecated. ` +
339
338
  `Please update to use ${colors_1.default.strong('loggingBehavior')} instead.`);
340
339
  }
340
+ if (typeof config.extConfig.bundledWebRuntime !== 'undefined') {
341
+ let actionMessage = `Can be safely deleted.`;
342
+ if (config.extConfig.bundledWebRuntime === true) {
343
+ actionMessage = `Please, use a bundler to bundle Capacitor and its plugins.`;
344
+ }
345
+ log_1.logger.warn(`The ${colors_1.default.strong('bundledWebRuntime')} configuration option has been deprecated. ${actionMessage}`);
346
+ }
341
347
  }
342
348
  exports.checkExternalConfig = checkExternalConfig;