pake-cli 0.0.1-beta.9 → 0.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.
Files changed (90) hide show
  1. package/.ecrc.json +3 -0
  2. package/.editorconfig +24 -0
  3. package/.github/FUNDING.yml +2 -2
  4. package/.github/ISSUE_TEMPLATE/bug.md +13 -0
  5. package/.github/workflows/editorconfig-check.yml +23 -0
  6. package/.github/workflows/main.yml +17 -0
  7. package/.github/workflows/rust-code-quality-check.yml +89 -0
  8. package/.prettierignore +4 -0
  9. package/.vscode/settings.json +1 -0
  10. package/CODE_OF_CONDUCT.md +128 -0
  11. package/CONTRIBUTING.md +26 -0
  12. package/LICENSE +21 -0
  13. package/README.md +175 -54
  14. package/README_EN.md +91 -53
  15. package/app.csv +9 -0
  16. package/bin/README.md +72 -0
  17. package/bin/builders/MacBuilder.ts +13 -14
  18. package/bin/builders/base.ts +10 -1
  19. package/bin/builders/common.ts +9 -4
  20. package/bin/cli.ts +12 -5
  21. package/bin/defaults.ts +1 -0
  22. package/bin/options/icon.ts +51 -53
  23. package/bin/options/index.ts +3 -5
  24. package/bin/types.ts +3 -3
  25. package/bin/utils/shell.ts +1 -0
  26. package/bin/utils/tlds.ts +1489 -0
  27. package/bin/utils/url.ts +26 -0
  28. package/dist/cli.js +1620 -101
  29. package/dist/twitter.css +176 -0
  30. package/icns2png.py +38 -0
  31. package/package.json +8 -7
  32. package/pake-default.icns +0 -0
  33. package/rollup.config.js +1 -1
  34. package/script/build.bat +80 -0
  35. package/script/build.sh +122 -0
  36. package/script/sd-apple-x64 +0 -0
  37. package/script/sd-linux-x64 +0 -0
  38. package/script/sd.exe +0 -0
  39. package/src-tauri/Cargo.lock +344 -65
  40. package/src-tauri/Cargo.toml +14 -6
  41. package/src-tauri/assets/com-tw93-weread.desktop +10 -0
  42. package/src-tauri/build.rs +1 -1
  43. package/src-tauri/icons/icon.icns +0 -0
  44. package/src-tauri/icons/reference.icns +0 -0
  45. package/src-tauri/icons/translate.icns +0 -0
  46. package/src-tauri/icons/twitter.icns +0 -0
  47. package/src-tauri/icons/{weRead.icns → weread.icns} +0 -0
  48. package/src-tauri/icons/youtube.icns +0 -0
  49. package/src-tauri/png/code_256.ico +0 -0
  50. package/src-tauri/png/code_32.ico +0 -0
  51. package/src-tauri/png/code_512.png +0 -0
  52. package/src-tauri/png/flomo_256.ico +0 -0
  53. package/src-tauri/png/flomo_32.ico +0 -0
  54. package/src-tauri/png/flomo_512.png +0 -0
  55. package/src-tauri/png/reference_256.ico +0 -0
  56. package/src-tauri/png/reference_32.ico +0 -0
  57. package/src-tauri/png/reference_512.png +0 -0
  58. package/src-tauri/png/tool_256.ico +0 -0
  59. package/src-tauri/png/tool_32.ico +0 -0
  60. package/src-tauri/png/tool_512.png +0 -0
  61. package/src-tauri/png/translate_256.ico +0 -0
  62. package/src-tauri/png/translate_32.ico +0 -0
  63. package/src-tauri/png/translate_512.png +0 -0
  64. package/src-tauri/png/twitter_256.ico +0 -0
  65. package/src-tauri/png/twitter_32.ico +0 -0
  66. package/src-tauri/png/twitter_512.png +0 -0
  67. package/src-tauri/png/weread_256.ico +0 -0
  68. package/src-tauri/png/weread_32.ico +0 -0
  69. package/src-tauri/png/weread_512.png +0 -0
  70. package/src-tauri/png/witeboard_256.ico +0 -0
  71. package/src-tauri/png/witeboard_32.ico +0 -0
  72. package/src-tauri/png/witeboard_512.png +0 -0
  73. package/src-tauri/png/youtube_256.ico +0 -0
  74. package/src-tauri/png/youtube_32.ico +0 -0
  75. package/src-tauri/png/youtube_512.png +0 -0
  76. package/src-tauri/png/yuque_256.ico +0 -0
  77. package/src-tauri/png/yuque_32.ico +0 -0
  78. package/src-tauri/png/yuque_512.png +0 -0
  79. package/src-tauri/src/main.rs +130 -25
  80. package/src-tauri/src/pake.js +140 -77
  81. package/src-tauri/tauri.conf.json +30 -13
  82. package/bin/options/title.ts +0 -14
  83. package/src-tauri/icons/anymind.icns +0 -0
  84. package/src-tauri/icons/fanfou.icns +0 -0
  85. package/src-tauri/icons/fone.icns +0 -0
  86. package/src-tauri/icons/jdread.icns +0 -0
  87. package/src-tauri/icons/jike.icns +0 -0
  88. package/src-tauri/icons/roam.icns +0 -0
  89. package/src-tauri/icons/vercel.icns +0 -0
  90. package/src-tauri/icons/whatsapp.icns +0 -0
@@ -1,18 +1,17 @@
1
1
  {
2
2
  "package": {
3
- "productName": "baidu",
3
+ "productName": "weread",
4
4
  "version": "0.2.0"
5
5
  },
6
6
  "tauri": {
7
7
  "windows": [
8
8
  {
9
- "url": "https://baidu.com",
10
- "transparent": false,
9
+ "url": "https://weread.qq.com/",
10
+ "transparent": true,
11
11
  "fullscreen": false,
12
- "width": 1280,
13
- "height": 800,
14
- "resizable": true,
15
- "title": "百度一下,你就知道"
12
+ "width": 1200,
13
+ "height": 728,
14
+ "resizable": true
16
15
  }
17
16
  ],
18
17
  "allowlist": {
@@ -20,16 +19,31 @@
20
19
  },
21
20
  "bundle": {
22
21
  "icon": [
23
- "/var/folders/vd/8qqrr2yd6gbf23bgx5vhdzrm0000gn/T/tmp-91408-NUAYXSkVg43n/icon.icns"
22
+ "icons/weread.icns",
23
+ "png/weread_256.ico",
24
+ "png/weread_32.ico",
25
+ "png/weread_512.png"
24
26
  ],
27
+ "identifier": "com.tw93.weread",
25
28
  "active": true,
26
29
  "category": "DeveloperTool",
27
30
  "copyright": "",
28
31
  "deb": {
29
- "depends": []
32
+ "depends": [
33
+ "libwebkit2gtk-4.0-dev",
34
+ "build-essential",
35
+ "curl",
36
+ "wget",
37
+ "libssl-dev",
38
+ "libgtk-3-dev",
39
+ "libayatana-appindicator3-dev",
40
+ "librsvg2-dev"
41
+ ],
42
+ "files": {
43
+ "/usr/share/applications/com-tw93-weread.desktop": "assets/com-tw93-weread.desktop"
44
+ }
30
45
  },
31
46
  "externalBin": [],
32
- "identifier": "pake-bb6e08",
33
47
  "longDescription": "",
34
48
  "macOS": {
35
49
  "entitlements": null,
@@ -40,11 +54,14 @@
40
54
  },
41
55
  "resources": [],
42
56
  "shortDescription": "",
43
- "targets": "all",
57
+ "targets": ["deb", "msi", "dmg"],
44
58
  "windows": {
45
59
  "certificateThumbprint": null,
46
60
  "digestAlgorithm": "sha256",
47
- "timestampUrl": ""
61
+ "timestampUrl": "",
62
+ "wix": {
63
+ "language": ["en-US", "zh-CN"]
64
+ }
48
65
  }
49
66
  },
50
67
  "security": {
@@ -60,4 +77,4 @@
60
77
  "beforeBuildCommand": "",
61
78
  "beforeDevCommand": ""
62
79
  }
63
- }
80
+ }
@@ -1,14 +0,0 @@
1
- import axios from 'axios';
2
-
3
- const USER_AGENT = 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36';
4
-
5
- export async function getTitleByURL(url: string): Promise<string> {
6
- const { data } = await axios.get<string>(url, {
7
- headers: {
8
- // Fake user agent for pages like http://messenger.com
9
- 'User-Agent': USER_AGENT,
10
- },
11
- });
12
- const title = /<\s*title.*?>(?<title>.+?)<\s*\/title\s*?>/i.exec(data)?.groups?.title ?? 'Webapp';
13
- return title;
14
- }
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file