pake-cli 3.0.0-beta → 3.0.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.
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- <h4 align="right"><strong>English</strong> | <a href="https://github.com/tw93/Pake/blob/master/README_CN.md">简体中文</a> | <a href="https://github.com/tw93/Pake/blob/master/README_JP.md">日本語</a></h4>
1
+ <h4 align="right"><strong>English</strong> | <a href="https://github.com/tw93/Pake/blob/main/README_CN.md">简体中文</a> | <a href="https://github.com/tw93/Pake/blob/main/README_JP.md">日本語</a></h4>
2
2
  <p align="center">
3
3
  <img src=https://gw.alipayobjects.com/zos/k/fa/logo-modified.png width=138/>
4
4
  </p>
@@ -220,6 +220,13 @@ Pake's development can not be without these Hackers. They contributed a lot of c
220
220
  <sub><b>Pan93412</b></sub>
221
221
  </a>
222
222
  </td>
223
+ <td align="center">
224
+ <a href="https://github.com/stone-w4tch3r">
225
+ <img src="https://avatars.githubusercontent.com/u/100294019?v=4" width="90;" alt="stone-w4tch3r"/>
226
+ <br />
227
+ <sub><b>Данил Бизимов</b></sub>
228
+ </a>
229
+ </td>
223
230
  <td align="center">
224
231
  <a href="https://github.com/wanghanzhen">
225
232
  <img src="https://avatars.githubusercontent.com/u/25301012?v=4" width="90;" alt="wanghanzhen"/>
@@ -233,15 +240,15 @@ Pake's development can not be without these Hackers. They contributed a lot of c
233
240
  <br />
234
241
  <sub><b>Bryan Lee</b></sub>
235
242
  </a>
236
- </td>
243
+ </td></tr>
244
+ <tr>
237
245
  <td align="center">
238
246
  <a href="https://github.com/essesoul">
239
247
  <img src="https://avatars.githubusercontent.com/u/58624474?v=4" width="90;" alt="essesoul"/>
240
248
  <br />
241
249
  <sub><b>Essesoul</b></sub>
242
250
  </a>
243
- </td></tr>
244
- <tr>
251
+ </td>
245
252
  <td align="center">
246
253
  <a href="https://github.com/YangguangZhou">
247
254
  <img src="https://avatars.githubusercontent.com/u/61733195?v=4" width="90;" alt="YangguangZhou"/>
@@ -277,6 +284,14 @@ Pake's development can not be without these Hackers. They contributed a lot of c
277
284
  <sub><b>Ikko Eltociear Ashimine</b></sub>
278
285
  </a>
279
286
  </td>
287
+ <td align="center">
288
+ <a href="https://github.com/mattbajorek">
289
+ <img src="https://avatars.githubusercontent.com/u/17235301?v=4" width="90;" alt="mattbajorek"/>
290
+ <br />
291
+ <sub><b>Matt Bajorek</b></sub>
292
+ </a>
293
+ </td></tr>
294
+ <tr>
280
295
  <td align="center">
281
296
  <a href="https://github.com/QingZ11">
282
297
  <img src="https://avatars.githubusercontent.com/u/38887077?v=4" width="90;" alt="QingZ11"/>
@@ -284,14 +299,27 @@ Pake's development can not be without these Hackers. They contributed a lot of c
284
299
  <sub><b>Steam</b></sub>
285
300
  </a>
286
301
  </td>
302
+ <td align="center">
303
+ <a href="https://github.com/Tianj0o">
304
+ <img src="https://avatars.githubusercontent.com/u/68584284?v=4" width="90;" alt="Tianj0o"/>
305
+ <br />
306
+ <sub><b>Qitianjia</b></sub>
307
+ </a>
308
+ </td>
309
+ <td align="center">
310
+ <a href="https://github.com/xinyii">
311
+ <img src="https://avatars.githubusercontent.com/u/17895104?v=4" width="90;" alt="xinyii"/>
312
+ <br />
313
+ <sub><b>Yi Xin</b></sub>
314
+ </a>
315
+ </td>
287
316
  <td align="center">
288
317
  <a href="https://github.com/exposir">
289
318
  <img src="https://avatars.githubusercontent.com/u/33340988?v=4" width="90;" alt="exposir"/>
290
319
  <br />
291
320
  <sub><b>孟世博</b></sub>
292
321
  </a>
293
- </td></tr>
294
- <tr>
322
+ </td>
295
323
  <td align="center">
296
324
  <a href="https://github.com/2nthony">
297
325
  <img src="https://avatars.githubusercontent.com/u/19513289?v=4" width="90;" alt="2nthony"/>
@@ -312,7 +340,8 @@ Pake's development can not be without these Hackers. They contributed a lot of c
312
340
  <br />
313
341
  <sub><b>Abu Taher Siddik</b></sub>
314
342
  </a>
315
- </td>
343
+ </td></tr>
344
+ <tr>
316
345
  <td align="center">
317
346
  <a href="https://github.com/kidylee">
318
347
  <img src="https://avatars.githubusercontent.com/u/841310?v=4" width="90;" alt="kidylee"/>
@@ -340,8 +369,7 @@ Pake's development can not be without these Hackers. They contributed a lot of c
340
369
  <br />
341
370
  <sub><b>Fechin</b></sub>
342
371
  </a>
343
- </td></tr>
344
- <tr>
372
+ </td>
345
373
  <td align="center">
346
374
  <a href="https://github.com/ImgBotApp">
347
375
  <img src="https://avatars.githubusercontent.com/u/31427850?v=4" width="90;" alt="ImgBotApp"/>
@@ -356,20 +384,14 @@ Pake's development can not be without these Hackers. They contributed a lot of c
356
384
  <sub><b>Jiaqi Gu</b></sub>
357
385
  </a>
358
386
  </td>
359
- <td align="center">
360
- <a href="https://github.com/mattbajorek">
361
- <img src="https://avatars.githubusercontent.com/u/17235301?v=4" width="90;" alt="mattbajorek"/>
362
- <br />
363
- <sub><b>Matt Bajorek</b></sub>
364
- </a>
365
- </td>
366
387
  <td align="center">
367
388
  <a href="https://github.com/Milo123459">
368
389
  <img src="https://avatars.githubusercontent.com/u/50248166?v=4" width="90;" alt="Milo123459"/>
369
390
  <br />
370
391
  <sub><b>Milo</b></sub>
371
392
  </a>
372
- </td>
393
+ </td></tr>
394
+ <tr>
373
395
  <td align="center">
374
396
  <a href="https://github.com/princemaple">
375
397
  <img src="https://avatars.githubusercontent.com/u/1329716?v=4" width="90;" alt="princemaple"/>
@@ -377,21 +399,13 @@ Pake's development can not be without these Hackers. They contributed a lot of c
377
399
  <sub><b>Po Chen</b></sub>
378
400
  </a>
379
401
  </td>
380
- <td align="center">
381
- <a href="https://github.com/Tianj0o">
382
- <img src="https://avatars.githubusercontent.com/u/68584284?v=4" width="90;" alt="Tianj0o"/>
383
- <br />
384
- <sub><b>Qitianjia</b></sub>
385
- </a>
386
- </td>
387
402
  <td align="center">
388
403
  <a href="https://github.com/geekvest">
389
404
  <img src="https://avatars.githubusercontent.com/u/126322776?v=4" width="90;" alt="geekvest"/>
390
405
  <br />
391
406
  <sub><b>Null</b></sub>
392
407
  </a>
393
- </td></tr>
394
- <tr>
408
+ </td>
395
409
  <td align="center">
396
410
  <a href="https://github.com/houhoz">
397
411
  <img src="https://avatars.githubusercontent.com/u/19684376?v=4" width="90;" alt="houhoz"/>
@@ -426,7 +440,8 @@ Pake's development can not be without these Hackers. They contributed a lot of c
426
440
  <br />
427
441
  <sub><b>Ranger</b></sub>
428
442
  </a>
429
- </td>
443
+ </td></tr>
444
+ <tr>
430
445
  <td align="center">
431
446
  <a href="https://github.com/hetz">
432
447
  <img src="https://avatars.githubusercontent.com/u/820141?v=4" width="90;" alt="hetz"/>
package/dist/cli.js CHANGED
@@ -20,7 +20,7 @@ import * as psl from 'psl';
20
20
  import isUrl from 'is-url';
21
21
 
22
22
  var name = "pake-cli";
23
- var version$1 = "3.0.0-beta";
23
+ var version$1 = "3.0.2";
24
24
  var description = "🤱🏻 Turn any webpage into a desktop app with Rust. 🤱🏻 利用 Rust 轻松构建轻量级多端桌面应用。";
25
25
  var engines = {
26
26
  node: ">=16.0.0"
@@ -69,8 +69,8 @@ var license = "MIT";
69
69
  var dependencies = {
70
70
  "@tauri-apps/api": "^1.6.0",
71
71
  "@tauri-apps/cli": "^2.1.0",
72
- axios: "^1.7.8",
73
- chalk: "^5.3.0",
72
+ axios: "^1.7.9",
73
+ chalk: "^5.4.0",
74
74
  commander: "^11.1.0",
75
75
  "file-type": "^18.7.0",
76
76
  "fs-extra": "^11.2.0",
@@ -91,7 +91,7 @@ var devDependencies = {
91
91
  "@rollup/plugin-terser": "^0.4.4",
92
92
  "@types/fs-extra": "^11.0.4",
93
93
  "@types/is-url": "^1.2.32",
94
- "@types/node": "^20.17.9",
94
+ "@types/node": "^20.17.10",
95
95
  "@types/page-icon": "^0.3.6",
96
96
  "@types/prompts": "^2.4.9",
97
97
  "@types/psl": "^1.1.3",
@@ -100,7 +100,7 @@ var devDependencies = {
100
100
  "@types/update-notifier": "^6.0.8",
101
101
  "app-root-path": "^3.1.0",
102
102
  "cross-env": "^7.0.3",
103
- rollup: "^4.28.0",
103
+ rollup: "^4.29.1",
104
104
  "rollup-plugin-typescript2": "^0.36.0",
105
105
  tslib: "^2.8.1",
106
106
  typescript: "^5.7.2"
@@ -163,30 +163,22 @@ var pakeConf = {
163
163
 
164
164
  var productName$1 = "WeRead";
165
165
  var identifier = "com.pake.weread";
166
- var version = "2.0.0";
167
- var plugins = {
168
- };
166
+ var version = "1.0.0";
169
167
  var app = {
170
- security: {
171
- csp: null
172
- },
168
+ withGlobalTauri: true,
173
169
  trayIcon: {
174
170
  iconPath: "png/weread_512.png",
175
171
  iconAsTemplate: false,
176
172
  id: "pake-tray"
177
- },
178
- withGlobalTauri: true
173
+ }
179
174
  };
180
175
  var build = {
181
- beforeBuildCommand: "",
182
- frontendDist: "../dist",
183
- beforeDevCommand: ""
176
+ frontendDist: "../dist"
184
177
  };
185
178
  var CommonConf = {
186
179
  productName: productName$1,
187
180
  identifier: identifier,
188
181
  version: version,
189
- plugins: plugins,
190
182
  app: app,
191
183
  build: build
192
184
  };
@@ -197,22 +189,14 @@ var bundle$2 = {
197
189
  "png/weread_32.ico"
198
190
  ],
199
191
  active: true,
200
- category: "DeveloperTool",
201
- copyright: "",
202
- externalBin: [
203
- ],
204
- longDescription: "",
205
192
  resources: [
206
193
  "png/weread_32.ico"
207
194
  ],
208
- shortDescription: "",
209
195
  targets: [
210
196
  "msi"
211
197
  ],
212
198
  windows: {
213
- certificateThumbprint: null,
214
199
  digestAlgorithm: "sha256",
215
- timestampUrl: "",
216
200
  wix: {
217
201
  language: [
218
202
  "en-US"
@@ -230,22 +214,8 @@ var bundle$1 = {
230
214
  "icons/weread.icns"
231
215
  ],
232
216
  active: true,
233
- category: "DeveloperTool",
234
- copyright: "",
235
- externalBin: [
236
- ],
237
- longDescription: "",
238
217
  macOS: {
239
- entitlements: null,
240
- exceptionDomain: null,
241
- frameworks: [
242
- ],
243
- providerShortName: null,
244
- signingIdentity: null
245
218
  },
246
- resources: [
247
- ],
248
- shortDescription: "",
249
219
  targets: [
250
220
  "dmg"
251
221
  ]
@@ -254,14 +224,12 @@ var MacConf = {
254
224
  bundle: bundle$1
255
225
  };
256
226
 
257
- var productName = "weread";
227
+ var productName = "we-read";
258
228
  var bundle = {
259
229
  icon: [
260
230
  "png/weread_512.png"
261
231
  ],
262
232
  active: true,
263
- category: "DeveloperTool",
264
- copyright: "",
265
233
  linux: {
266
234
  deb: {
267
235
  depends: [
@@ -273,12 +241,6 @@ var bundle = {
273
241
  }
274
242
  }
275
243
  },
276
- externalBin: [
277
- ],
278
- longDescription: "",
279
- resources: [
280
- ],
281
- shortDescription: "",
282
244
  targets: [
283
245
  "deb",
284
246
  "appimage"
@@ -419,7 +381,7 @@ async function isChinaIP(ip, domain) {
419
381
  try {
420
382
  const delay = await ping(ip);
421
383
  logger.debug(`${domain} latency is ${delay} ms`);
422
- return delay > 500;
384
+ return delay > 1000;
423
385
  }
424
386
  catch (error) {
425
387
  logger.debug(`ping ${domain} failed!`);
@@ -481,7 +443,7 @@ async function mergeConfig(url, options, tauriConf) {
481
443
  Object.assign(tauriConf.pake.windows[0], { url, ...tauriConfWindowOptions });
482
444
  tauriConf.productName = name;
483
445
  tauriConf.identifier = identifier;
484
- if (platform == "win32") {
446
+ if (platform == 'win32') {
485
447
  tauriConf.bundle.windows.wix.language[0] = installerLanguage;
486
448
  }
487
449
  //Judge the type of URL, whether it is a file or a website.
@@ -619,7 +581,7 @@ async function mergeConfig(url, options, tauriConf) {
619
581
  tauriConf.pake.inject = [];
620
582
  await fsExtra.writeFile(injectFilePath, '');
621
583
  }
622
- tauriConf.pake.proxy_url = proxyUrl || "";
584
+ tauriConf.pake.proxy_url = proxyUrl || '';
623
585
  // Save config file.
624
586
  const platformConfigPaths = {
625
587
  win32: 'tauri.windows.conf.json',
@@ -1006,10 +968,10 @@ program
1006
968
  .option('--fullscreen', 'Start in full screen', DEFAULT_PAKE_OPTIONS.fullscreen)
1007
969
  .option('--hide-title-bar', 'Only for Mac, hide title bar', DEFAULT_PAKE_OPTIONS.hideTitleBar)
1008
970
  .option('--activation-shortcut <string>', 'Shortcut key to active App', DEFAULT_PAKE_OPTIONS.activationShortcut)
1009
- .option('--multi-arch', 'Only for Mac, supports both Intel and M1', DEFAULT_PAKE_OPTIONS.multiArch)
1010
- .option('--inject [injects...]', 'Injection of .js or .css Files', DEFAULT_PAKE_OPTIONS.inject)
971
+ .option('--inject <url>', 'Injection of .js or .css files', DEFAULT_PAKE_OPTIONS.inject)
972
+ .option('--proxy-url <url>', "Proxy URL for all network requests", DEFAULT_PAKE_OPTIONS.proxyUrl)
1011
973
  .option('--debug', 'Debug build and more output', DEFAULT_PAKE_OPTIONS.debug)
1012
- .option('--proxy-url', "Proxy URL", DEFAULT_PAKE_OPTIONS.proxyUrl)
974
+ .option('--multi-arch', 'Only for Mac, supports both Intel and M1', DEFAULT_PAKE_OPTIONS.multiArch)
1013
975
  .addOption(new Option('--user-agent <string>', 'Custom user agent').default(DEFAULT_PAKE_OPTIONS.userAgent).hideHelp())
1014
976
  .addOption(new Option('--targets <string>', 'Only for Linux, option "deb" or "appimage"').default(DEFAULT_PAKE_OPTIONS.targets).hideHelp())
1015
977
  .addOption(new Option('--always-on-top', 'Always on the top level').default(DEFAULT_PAKE_OPTIONS.alwaysOnTop).hideHelp())
package/dist/dev.js CHANGED
@@ -263,30 +263,22 @@ var pakeConf = {
263
263
 
264
264
  var productName$1 = "WeRead";
265
265
  var identifier = "com.pake.weread";
266
- var version = "2.0.0";
267
- var plugins = {
268
- };
266
+ var version = "1.0.0";
269
267
  var app = {
270
- security: {
271
- csp: null
272
- },
268
+ withGlobalTauri: true,
273
269
  trayIcon: {
274
270
  iconPath: "png/weread_512.png",
275
271
  iconAsTemplate: false,
276
272
  id: "pake-tray"
277
- },
278
- withGlobalTauri: true
273
+ }
279
274
  };
280
275
  var build = {
281
- beforeBuildCommand: "",
282
- frontendDist: "../dist",
283
- beforeDevCommand: ""
276
+ frontendDist: "../dist"
284
277
  };
285
278
  var CommonConf = {
286
279
  productName: productName$1,
287
280
  identifier: identifier,
288
281
  version: version,
289
- plugins: plugins,
290
282
  app: app,
291
283
  build: build
292
284
  };
@@ -297,22 +289,14 @@ var bundle$2 = {
297
289
  "png/weread_32.ico"
298
290
  ],
299
291
  active: true,
300
- category: "DeveloperTool",
301
- copyright: "",
302
- externalBin: [
303
- ],
304
- longDescription: "",
305
292
  resources: [
306
293
  "png/weread_32.ico"
307
294
  ],
308
- shortDescription: "",
309
295
  targets: [
310
296
  "msi"
311
297
  ],
312
298
  windows: {
313
- certificateThumbprint: null,
314
299
  digestAlgorithm: "sha256",
315
- timestampUrl: "",
316
300
  wix: {
317
301
  language: [
318
302
  "en-US"
@@ -330,22 +314,8 @@ var bundle$1 = {
330
314
  "icons/weread.icns"
331
315
  ],
332
316
  active: true,
333
- category: "DeveloperTool",
334
- copyright: "",
335
- externalBin: [
336
- ],
337
- longDescription: "",
338
317
  macOS: {
339
- entitlements: null,
340
- exceptionDomain: null,
341
- frameworks: [
342
- ],
343
- providerShortName: null,
344
- signingIdentity: null
345
318
  },
346
- resources: [
347
- ],
348
- shortDescription: "",
349
319
  targets: [
350
320
  "dmg"
351
321
  ]
@@ -354,14 +324,12 @@ var MacConf = {
354
324
  bundle: bundle$1
355
325
  };
356
326
 
357
- var productName = "weread";
327
+ var productName = "we-read";
358
328
  var bundle = {
359
329
  icon: [
360
330
  "png/weread_512.png"
361
331
  ],
362
332
  active: true,
363
- category: "DeveloperTool",
364
- copyright: "",
365
333
  linux: {
366
334
  deb: {
367
335
  depends: [
@@ -373,12 +341,6 @@ var bundle = {
373
341
  }
374
342
  }
375
343
  },
376
- externalBin: [
377
- ],
378
- longDescription: "",
379
- resources: [
380
- ],
381
- shortDescription: "",
382
344
  targets: [
383
345
  "deb",
384
346
  "appimage"
@@ -521,10 +483,10 @@ async function mergeConfig(url, options, tauriConf) {
521
483
  disabled_web_shortcuts: disabledWebShortcuts,
522
484
  };
523
485
  Object.assign(tauriConf.pake.windows[0], { url, ...tauriConfWindowOptions });
524
- tauriConf.package.productName = name;
525
- tauriConf.tauri.bundle.identifier = identifier;
526
- if (platform == "win32") {
527
- tauriConf.tauri.bundle.windows.wix.language[0] = installerLanguage;
486
+ tauriConf.productName = name;
487
+ tauriConf.identifier = identifier;
488
+ if (platform == 'win32') {
489
+ tauriConf.bundle.windows.wix.language[0] = installerLanguage;
528
490
  }
529
491
  //Judge the type of URL, whether it is a file or a website.
530
492
  const pathExists = await fsExtra.pathExists(url);
@@ -661,7 +623,7 @@ async function mergeConfig(url, options, tauriConf) {
661
623
  tauriConf.pake.inject = [];
662
624
  await fsExtra.writeFile(injectFilePath, '');
663
625
  }
664
- tauriConf.pake.proxy_url = proxyUrl || "";
626
+ tauriConf.pake.proxy_url = proxyUrl || '';
665
627
  // Save config file.
666
628
  const platformConfigPaths = {
667
629
  win32: 'tauri.windows.conf.json',