electron-incremental-update 0.9.1 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/vite.mjs CHANGED
@@ -1,18 +1,24 @@
1
1
  import {
2
- isUpdateJSON,
3
2
  signature
4
- } from "./chunk-5BZLJPHJ.mjs";
3
+ } from "./chunk-GXZSAUBR.mjs";
5
4
  import {
5
+ isUpdateJSON,
6
6
  parseVersion,
7
7
  zipFile
8
- } from "./chunk-CMBFI77K.mjs";
8
+ } from "./chunk-GB6VLKJZ.mjs";
9
9
 
10
10
  // src/vite.ts
11
- import { createLogger } from "vite";
11
+ import { join as join2, resolve } from "node:path";
12
+ import { rmSync } from "node:fs";
13
+ import { createLogger, mergeConfig, normalizePath } from "vite";
14
+ import ElectronSimple from "vite-plugin-electron/simple";
15
+ import { startup } from "vite-plugin-electron";
16
+ import { notBundle } from "vite-plugin-electron/plugin";
12
17
 
13
18
  // src/build-plugins/build.ts
14
19
  import { readFile, rename, writeFile } from "node:fs/promises";
15
- import { existsSync } from "node:fs";
20
+ import { cpSync, existsSync } from "node:fs";
21
+ import { basename, join } from "node:path";
16
22
  import Asar from "@electron/asar";
17
23
  import { build } from "esbuild";
18
24
  async function buildAsar({
@@ -22,8 +28,8 @@ async function buildAsar({
22
28
  electronDistPath,
23
29
  rendererDistPath
24
30
  }) {
25
- await rename(rendererDistPath, `${electronDistPath}/renderer`);
26
- await writeFile(`${electronDistPath}/version`, version);
31
+ await rename(rendererDistPath, join(electronDistPath, "renderer"));
32
+ await writeFile(join(electronDistPath, "version"), version);
27
33
  await Asar.createPackage(electronDistPath, asarOutputPath);
28
34
  await zipFile(asarOutputPath, gzipPath);
29
35
  }
@@ -51,13 +57,15 @@ async function buildVersion({
51
57
  };
52
58
  if (existsSync(versionPath)) {
53
59
  try {
54
- _json = JSON.parse(await readFile(versionPath, "utf-8"));
60
+ const oldVersionJson = JSON.parse(await readFile(versionPath, "utf-8"));
61
+ if (isUpdateJSON(oldVersionJson)) {
62
+ _json = oldVersionJson;
63
+ } else {
64
+ console.warn("old version json is invalid, ignore it");
65
+ }
55
66
  } catch (error) {
56
67
  }
57
68
  }
58
- if (!isUpdateJSON(_json)) {
59
- throw new Error("invalid version file");
60
- }
61
69
  const buffer = await readFile(gzipPath);
62
70
  const sig = await (generateSignature ?? signature)(buffer, privateKey, cert, version);
63
71
  if (generateVersionJson) {
@@ -66,10 +74,12 @@ async function buildVersion({
66
74
  throw new Error("invalid version info");
67
75
  }
68
76
  } else {
69
- _json.beta.version = version;
70
- _json.beta.minimumVersion = minimumVersion;
71
- _json.beta.signature = sig;
72
- _json.beta.size = buffer.length;
77
+ _json.beta = {
78
+ version,
79
+ minimumVersion,
80
+ signature: sig,
81
+ size: buffer.length
82
+ };
73
83
  if (!parseVersion(version).stage) {
74
84
  _json.version = version;
75
85
  _json.minimumVersion = minimumVersion;
@@ -80,17 +90,44 @@ async function buildVersion({
80
90
  await writeFile(versionPath, JSON.stringify(_json, null, 2));
81
91
  }
82
92
  async function buildEntry({
83
- entryPath,
84
- entryOutputPath: outfile,
85
- minify
93
+ sourcemap,
94
+ minify,
95
+ appEntryPath,
96
+ entryOutputDirPath,
97
+ nativeModuleEntryMap,
98
+ overrideEsbuildOptions,
99
+ postBuild
86
100
  }) {
87
101
  await build({
88
- entryPoints: [entryPath],
102
+ entryPoints: {
103
+ entry: appEntryPath,
104
+ ...nativeModuleEntryMap
105
+ },
89
106
  bundle: true,
90
107
  platform: "node",
91
- outfile,
108
+ outdir: entryOutputDirPath,
92
109
  minify,
93
- external: ["electron", "original-fs"]
110
+ sourcemap,
111
+ entryNames: "[dir]/[name]",
112
+ assetNames: "[dir]/[name]",
113
+ external: ["electron", "original-fs"],
114
+ loader: {
115
+ ".node": "empty"
116
+ },
117
+ ...overrideEsbuildOptions
118
+ });
119
+ await postBuild?.({
120
+ getPathFromEntryOutputDir(...paths) {
121
+ return join(entryOutputDirPath, ...paths);
122
+ },
123
+ existsAndCopyToEntryOutputDir({ from, to, skipIfExist = true }) {
124
+ if (existsSync(from)) {
125
+ const target = join(entryOutputDirPath, to ?? basename(from));
126
+ if (!skipIfExist || !existsSync(target)) {
127
+ cpSync(from, target);
128
+ }
129
+ }
130
+ }
94
131
  });
95
132
  }
96
133
 
@@ -115,31 +152,21 @@ function generateKeyPair(keyLength, subject, days, privateKeyPath, certPath) {
115
152
  writeFileSync(privateKeyPath, privateKey.replace(/\r\n?/g, "\n"));
116
153
  writeFileSync(certPath, cert.replace(/\r\n?/g, "\n"));
117
154
  }
118
- function writeCertToMain(entryPath, cert) {
155
+ var noCertRegex = /(?<=const SIGNATURE_CERT\s*=\s*)['"]{2}/m;
156
+ var existCertRegex = /(?<=const SIGNATURE_CERT\s*=\s*)(['"]-----BEGIN CERTIFICATE-----[\s\S]*-----END CERTIFICATE-----\\n['"])/m;
157
+ function writeCertToEntry(entryPath, cert) {
158
+ if (!existsSync2(entryPath)) {
159
+ throw new Error(`entry not exist: ${entryPath}`);
160
+ }
119
161
  const file = readFileSync(entryPath, "utf-8");
120
- const initRegex = /(?<=const SIGNATURE_CERT\s*=\s*)['"]{2}/m;
121
- const existRegex = /(?<=const SIGNATURE_CERT\s*=\s*)(['"]-----BEGIN CERTIFICATE-----[\s\S]*-----END CERTIFICATE-----\\n['"])/m;
122
- const eol = file.includes("\r") ? "\r\n" : "\n";
123
- const replacement = cert.split("\n").filter(Boolean).map((s) => `'${s}\\n'`).join(`${eol} + `);
162
+ const replacement = cert.split("\n").filter(Boolean).map((s) => `'${s}\\n'`).join("\n + ");
124
163
  let replaced = file;
125
- if (initRegex.test(file)) {
126
- replaced = file.replace(initRegex, replacement);
127
- } else if (existRegex.test(file)) {
128
- replaced = file.replace(existRegex, replacement);
164
+ if (noCertRegex.test(file)) {
165
+ replaced = file.replace(noCertRegex, replacement);
166
+ } else if (existCertRegex.test(file)) {
167
+ replaced = file.replace(existCertRegex, replacement);
129
168
  } else {
130
- const lines = file.split(eol);
131
- const r = `${eol}const SIGNATURE_CERT = ${replacement}${eol}`;
132
- let isMatched = false;
133
- for (let i = 0; i < lines.length; i++) {
134
- const line = lines[i];
135
- if (!line.startsWith("import") && !line.startsWith("/")) {
136
- lines.splice(i, 0, r);
137
- isMatched = true;
138
- break;
139
- }
140
- }
141
- !isMatched && lines.push(r);
142
- replaced = lines.join(eol);
169
+ throw new Error("no `SIGNATURE_CERT` found in entry");
143
170
  }
144
171
  writeFileSync(entryPath, replaced);
145
172
  }
@@ -147,45 +174,41 @@ function parseKeys({
147
174
  keyLength,
148
175
  privateKeyPath,
149
176
  certPath,
150
- entryPath,
177
+ appEntryPath,
151
178
  subject,
152
179
  days
153
180
  }) {
154
181
  const keysDir = dirname(privateKeyPath);
155
182
  !existsSync2(keysDir) && mkdirSync(keysDir);
156
183
  if (!existsSync2(privateKeyPath) || !existsSync2(certPath)) {
184
+ console.warn("no key pair found, generate new key pair");
157
185
  generateKeyPair(keyLength, parseSubjects(subject), days, privateKeyPath, certPath);
158
186
  }
159
187
  const privateKey = process.env.UPDATER_PK || readFileSync(privateKeyPath, "utf-8");
160
188
  const cert = process.env.UPDATER_CERT || readFileSync(certPath, "utf-8");
161
- writeCertToMain(entryPath, cert);
162
- return {
163
- privateKey,
164
- cert
165
- };
189
+ writeCertToEntry(appEntryPath, cert);
190
+ return { privateKey, cert };
166
191
  }
167
192
  function parseSubjects(subject) {
168
- const ret = [];
169
- Object.keys(subject).forEach((name) => {
170
- const value = subject[name];
171
- value && ret.push({ name, value });
172
- });
173
- return ret;
193
+ return Object.entries(subject).filter(([_, value]) => !!value).map(([name, value]) => ({ name, value }));
174
194
  }
175
195
 
176
196
  // src/build-plugins/option.ts
177
- function parseOptions(options) {
197
+ function parseOptions(isBuild, pkg, options = {}) {
178
198
  const {
179
- isBuild,
180
- productName,
181
- version,
182
- minimumVersion = version,
183
- minify = false,
199
+ minimumVersion = "0.0.0",
200
+ entry: {
201
+ minify = isBuild,
202
+ sourcemap = isBuild,
203
+ entryOutputDirPath = "dist-entry",
204
+ appEntryPath = "electron/entry.ts",
205
+ nativeModuleEntryMap = {},
206
+ postBuild,
207
+ overrideEsbuildOptions
208
+ } = {},
184
209
  paths: {
185
- entryPath = "electron/app.ts",
186
- entryOutputPath = "app.js",
187
- asarOutputPath = `release/${productName}.asar`,
188
- gzipPath = `release/${productName}-${version}.asar.gz`,
210
+ asarOutputPath = `release/${pkg.name}.asar`,
211
+ gzipPath = `release/${pkg.name}-${pkg.version}.asar.gz`,
189
212
  electronDistPath = "dist-electron",
190
213
  rendererDistPath = "dist",
191
214
  versionPath = "version.json"
@@ -195,39 +218,43 @@ function parseOptions(options) {
195
218
  certPath = "keys/cert.pem",
196
219
  keyLength = 2048,
197
220
  certInfo = {},
198
- overrideFunctions = {}
221
+ overrideGenerator = {}
199
222
  } = {}
200
223
  } = options;
201
- const { generateSignature, generateVersionJson } = overrideFunctions;
224
+ const { generateSignature, generateVersionJson } = overrideGenerator;
202
225
  let {
203
226
  subject = {
204
- commonName: productName,
205
- organizationName: `org.${productName}`
227
+ commonName: pkg.name,
228
+ organizationName: `org.${pkg.name}`
206
229
  },
207
- days = 365
230
+ days = 3650
208
231
  } = certInfo;
209
232
  const buildAsarOption = {
210
- version,
233
+ version: pkg.version,
211
234
  asarOutputPath,
212
235
  gzipPath,
213
236
  electronDistPath,
214
237
  rendererDistPath
215
238
  };
216
239
  const buildEntryOption = {
217
- entryPath,
218
- entryOutputPath,
219
- minify
240
+ minify,
241
+ sourcemap,
242
+ entryOutputDirPath,
243
+ appEntryPath,
244
+ nativeModuleEntryMap,
245
+ postBuild,
246
+ overrideEsbuildOptions
220
247
  };
221
248
  const { privateKey, cert } = parseKeys({
222
249
  keyLength,
223
250
  privateKeyPath,
224
251
  certPath,
225
- entryPath,
252
+ appEntryPath,
226
253
  subject,
227
254
  days
228
255
  });
229
256
  const buildVersionOption = {
230
- version,
257
+ version: pkg.version,
231
258
  minimumVersion,
232
259
  gzipPath,
233
260
  privateKey,
@@ -236,33 +263,130 @@ function parseOptions(options) {
236
263
  generateSignature,
237
264
  generateVersionJson
238
265
  };
239
- return { isBuild, buildAsarOption, buildEntryOption, buildVersionOption };
266
+ return { buildAsarOption, buildEntryOption, buildVersionOption };
240
267
  }
241
268
 
242
269
  // src/vite.ts
243
- function ElectronUpdater(options) {
244
- const { isBuild, buildAsarOption, buildEntryOption, buildVersionOption } = parseOptions(options);
245
- const { entryPath, entryOutputPath } = buildEntryOption;
246
- const { asarOutputPath } = buildAsarOption;
247
- const id = "electron-incremental-updater";
248
- const log = createLogger("info", { prefix: `[${id}]` });
249
- return {
250
- name: `vite-plugin-${id}`,
251
- enforce: "post",
252
- async closeBundle() {
253
- log.info("build entry start", { timestamp: true });
254
- await buildEntry(buildEntryOption);
255
- log.info(`build entry end, ${entryPath} -> ${entryOutputPath}`, { timestamp: true });
256
- if (!isBuild) {
257
- return;
258
- }
259
- log.info("build asar start", { timestamp: true });
260
- await buildAsar(buildAsarOption);
261
- await buildVersion(buildVersionOption);
262
- log.info(`build asar end, output to ${asarOutputPath}`, { timestamp: true });
270
+ function debugStartup(args) {
271
+ process.env.VSCODE_DEBUG ? console.log("[startup] Electron App") : args.startup();
272
+ }
273
+ var id = "electron-incremental-updater";
274
+ var log = createLogger("info", { prefix: `[${id}]` });
275
+ function electronWithUpdater(options) {
276
+ const {
277
+ isBuild,
278
+ pkg,
279
+ main: _main,
280
+ preload: _preload,
281
+ updater,
282
+ useNotBundle = true,
283
+ logParsedOptions
284
+ } = options;
285
+ const _options = parseOptions(isBuild, pkg, updater);
286
+ try {
287
+ rmSync(_options.buildAsarOption.electronDistPath, { recursive: true, force: true });
288
+ rmSync(_options.buildEntryOption.entryOutputDirPath, { recursive: true, force: true });
289
+ } catch (ignore) {
290
+ }
291
+ log.info(`remove old files`, { timestamp: true });
292
+ const { buildAsarOption, buildEntryOption, buildVersionOption } = _options;
293
+ const { entryOutputDirPath, nativeModuleEntryMap, appEntryPath } = buildEntryOption;
294
+ const sourcemap = isBuild || !!process.env.VSCODE_DEBUG;
295
+ const _appPath = join2(entryOutputDirPath, "entry.js");
296
+ if (resolve(normalizePath(pkg.main)) !== resolve(normalizePath(_appPath))) {
297
+ throw new Error(`wrong "main" field in package.json: "${pkg.main}", it should be "${normalizePath(_appPath)}"`);
298
+ }
299
+ let isInit = false;
300
+ const _buildEntry = async () => {
301
+ await buildEntry(buildEntryOption);
302
+ log.info(`build entry to '${entryOutputDirPath}'`, { timestamp: true });
303
+ };
304
+ const electronPluginOptions = {
305
+ main: {
306
+ entry: _main.files,
307
+ onstart: async (args) => {
308
+ if (!isInit) {
309
+ isInit = true;
310
+ await _buildEntry();
311
+ }
312
+ _main.onstart?.(args) ?? args.startup();
313
+ },
314
+ vite: mergeConfig(
315
+ {
316
+ plugins: !isBuild && useNotBundle ? [notBundle()] : void 0,
317
+ build: {
318
+ sourcemap,
319
+ minify: isBuild,
320
+ outDir: `${buildAsarOption.electronDistPath}/main`,
321
+ rollupOptions: {
322
+ external: Object.keys("dependencies" in pkg ? pkg.dependencies : {})
323
+ }
324
+ }
325
+ },
326
+ _main.vite ?? {}
327
+ )
328
+ },
329
+ preload: {
330
+ input: _preload.files,
331
+ onstart: _preload.onstart,
332
+ vite: mergeConfig(
333
+ {
334
+ plugins: [
335
+ {
336
+ name: `${id}-build`,
337
+ enforce: "post",
338
+ apply() {
339
+ return isBuild;
340
+ },
341
+ async closeBundle() {
342
+ await _buildEntry();
343
+ await buildAsar(buildAsarOption);
344
+ log.info(`build asar to '${buildAsarOption.asarOutputPath}'`, { timestamp: true });
345
+ await buildVersion(buildVersionOption);
346
+ log.info(`build version info to '${buildVersionOption.versionPath}'`, { timestamp: true });
347
+ }
348
+ }
349
+ ],
350
+ build: {
351
+ sourcemap: sourcemap ? "inline" : void 0,
352
+ minify: isBuild,
353
+ outDir: `${buildAsarOption.electronDistPath}/preload`,
354
+ rollupOptions: {
355
+ external: Object.keys("dependencies" in pkg ? pkg.dependencies : {})
356
+ }
357
+ }
358
+ },
359
+ _preload.vite ?? {}
360
+ )
263
361
  }
264
362
  };
363
+ logParsedOptions && log.info(
364
+ JSON.stringify(
365
+ {
366
+ ...electronPluginOptions,
367
+ updater: { buildAsarOption, buildEntryOption, buildVersionOption }
368
+ },
369
+ (key, value) => key === "privateKey" || key === "cert" ? "***" : value,
370
+ 2
371
+ ),
372
+ { timestamp: true }
373
+ );
374
+ let extraHmrPlugin;
375
+ if (nativeModuleEntryMap) {
376
+ const files = [...Object.values(nativeModuleEntryMap), appEntryPath].map((file) => resolve(normalizePath(file)));
377
+ extraHmrPlugin = {
378
+ name: `${id}-dev`,
379
+ apply() {
380
+ return !isBuild;
381
+ },
382
+ configureServer: (server) => {
383
+ server.watcher.add(files).on("change", (p) => files.includes(p) && _buildEntry().then(() => startup()));
384
+ }
385
+ };
386
+ }
387
+ return [ElectronSimple(electronPluginOptions), extraHmrPlugin];
265
388
  }
266
389
  export {
267
- ElectronUpdater
390
+ debugStartup,
391
+ electronWithUpdater
268
392
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "electron-incremental-update",
3
- "version": "0.9.1",
3
+ "version": "1.0.1",
4
4
  "description": "electron incremental update tools, powered by vite",
5
5
  "author": "subframe7536",
6
6
  "license": "MIT",
@@ -45,22 +45,29 @@
45
45
  "registry": "https://registry.npmjs.org/"
46
46
  },
47
47
  "peerDependencies": {
48
- "esbuild": "*"
48
+ "esbuild": "*",
49
+ "vite-plugin-electron": "^0.15.6 || ^0.28"
49
50
  },
50
51
  "dependencies": {
51
52
  "@electron/asar": "^3.2.8",
52
- "ci-info": "^4.0.0",
53
+ "@subframe7536/type-utils": "^0.1.4",
53
54
  "selfsigned": "^2.4.1"
54
55
  },
55
56
  "devDependencies": {
56
- "@subframe7536/eslint-config": "^0.5.2",
57
- "@types/node": "^20.10.1",
58
- "bumpp": "^9.2.0",
59
- "electron": "^27.1.2",
60
- "eslint": "^8.54.0",
57
+ "@subframe7536/eslint-config": "^0.5.9",
58
+ "@types/node": "^20.11.5",
59
+ "bumpp": "^9.3.0",
60
+ "electron": "28.1.1",
61
+ "eslint": "^8.56.0",
61
62
  "tsup": "^8.0.1",
62
- "typescript": "^5.3.2",
63
- "vite": "^5.0.4",
64
- "vitest": "^0.34.6"
63
+ "typescript": "^5.3.3",
64
+ "vite": "^5.0.12",
65
+ "vite-plugin-electron": "^0.15.6",
66
+ "vitest": "^1.2.1"
67
+ },
68
+ "pnpm": {
69
+ "overrides": {
70
+ "has": "npm:@nolyfill/has@latest"
71
+ }
65
72
  }
66
73
  }
@@ -1,124 +0,0 @@
1
- import {
2
- __require
3
- } from "./chunk-CMBFI77K.mjs";
4
-
5
- // src/utils/core.ts
6
- import { existsSync, mkdirSync, readFileSync } from "node:fs";
7
- import { dirname, join } from "node:path";
8
- import { release } from "node:os";
9
- import { app } from "electron";
10
- var DEFAULT_APP_NAME = "product";
11
- var is = {
12
- dev: !app.isPackaged,
13
- win: process.platform === "win32",
14
- mac: process.platform === "darwin",
15
- linux: process.platform === "linux"
16
- };
17
- function getLocale() {
18
- return app.isReady() ? app.getLocale() : void 0;
19
- }
20
- function getProductAsarPath(name = DEFAULT_APP_NAME) {
21
- return !app.isPackaged ? join(dirname(app.getAppPath()), `${name}.asar`) : "DEV.asar";
22
- }
23
- function getElectronVersion() {
24
- return app.getVersion();
25
- }
26
- function getAppVersion(name = DEFAULT_APP_NAME) {
27
- return app.isPackaged ? readFileSync(join(getProductAsarPath(name), "version"), "utf-8") : getElectronVersion();
28
- }
29
- var NoSuchNativeModuleError = class extends Error {
30
- moduleName;
31
- constructor(moduleName) {
32
- super(`no such native module: ${moduleName}`);
33
- this.moduleName = moduleName;
34
- }
35
- };
36
- function isNoSuchNativeModuleError(e) {
37
- return e instanceof NoSuchNativeModuleError;
38
- }
39
- function requireNative(packageName) {
40
- const path = app.isPackaged ? join(app.getAppPath(), "node_modules", packageName) : packageName;
41
- try {
42
- return __require(path);
43
- } catch (error) {
44
- return new NoSuchNativeModuleError(packageName);
45
- }
46
- }
47
- function restartApp() {
48
- app.relaunch();
49
- app.quit();
50
- }
51
- function setAppUserModelId(id) {
52
- is.win && app.setAppUserModelId(is.dev ? process.execPath : id);
53
- }
54
- function disableHWAccForWin7() {
55
- if (release().startsWith("6.1")) {
56
- app.disableHardwareAcceleration();
57
- }
58
- }
59
- function singleInstance() {
60
- if (!app.requestSingleInstanceLock()) {
61
- app.quit();
62
- process.exit(0);
63
- }
64
- }
65
- function setPortableAppDataPath(dirName = "data", create) {
66
- if (!is.win) {
67
- return;
68
- }
69
- const portablePath = join(dirname(app.getPath("exe")), dirName);
70
- let exists = existsSync(portablePath);
71
- if (create && !exists) {
72
- mkdirSync(portablePath);
73
- exists = true;
74
- }
75
- if (exists) {
76
- app.setPath("appData", portablePath);
77
- }
78
- }
79
- function waitAppReady(timeout = 1e3) {
80
- return app.isReady() ? Promise.resolve() : new Promise((resolve, reject) => {
81
- const _ = setTimeout(() => {
82
- reject(new Error("app is not ready"));
83
- }, timeout);
84
- app.whenReady().then(() => {
85
- clearTimeout(_);
86
- resolve();
87
- });
88
- });
89
- }
90
-
91
- // src/utils/utils.ts
92
- function parseGithubCdnURL(originRepoURL, cdnPrefix, relativeFilePath) {
93
- if (!originRepoURL.startsWith("https://github.com/")) {
94
- throw new Error("origin url must start with https://github.com/");
95
- }
96
- originRepoURL = originRepoURL.trim().replace(/\/?$/, "/").trim();
97
- relativeFilePath = relativeFilePath.trim().replace(/^\/|\/?$/g, "").trim();
98
- cdnPrefix = cdnPrefix.trim().replace(/^\/?|\/?$/g, "").trim();
99
- return originRepoURL.replace("github.com", cdnPrefix) + relativeFilePath;
100
- }
101
- function handleUnexpectedErrors(callback) {
102
- process.on("uncaughtException", callback);
103
- process.on("unhandledRejection", callback);
104
- }
105
-
106
- export {
107
- DEFAULT_APP_NAME,
108
- is,
109
- getLocale,
110
- getProductAsarPath,
111
- getElectronVersion,
112
- getAppVersion,
113
- NoSuchNativeModuleError,
114
- isNoSuchNativeModuleError,
115
- requireNative,
116
- restartApp,
117
- setAppUserModelId,
118
- disableHWAccForWin7,
119
- singleInstance,
120
- setPortableAppDataPath,
121
- waitAppReady,
122
- parseGithubCdnURL,
123
- handleUnexpectedErrors
124
- };
@@ -1,11 +0,0 @@
1
- type UpdateInfo = {
2
- signature: string;
3
- minimumVersion: string;
4
- version: string;
5
- size: number;
6
- };
7
- type UpdateJSON = UpdateInfo & {
8
- beta: UpdateInfo;
9
- };
10
-
11
- export type { UpdateJSON as U };
@@ -1,11 +0,0 @@
1
- type UpdateInfo = {
2
- signature: string;
3
- minimumVersion: string;
4
- version: string;
5
- size: number;
6
- };
7
- type UpdateJSON = UpdateInfo & {
8
- beta: UpdateInfo;
9
- };
10
-
11
- export type { UpdateJSON as U };