-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #31 from baizeteam/dev
性能优化
- Loading branch information
Showing
10 changed files
with
89 additions
and
111 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"name": "baize-toolbox", | ||
"version": "0.0.1-beta3", | ||
"version": "0.0.1-beta4", | ||
"description": "An Electron application with React and TypeScript", | ||
"main": "./out/main/index.js", | ||
"author": "[email protected]", | ||
|
@@ -64,8 +64,8 @@ | |
"bufferutil": "^4.0.8", | ||
"dayjs": "^1.11.10", | ||
"easy-auto-launch": "^6.0.2", | ||
"electron": "^29.1.6", | ||
"electron-builder": "^24.9.1", | ||
"electron": "^31.0.1", | ||
"electron-builder": "^24.13.3", | ||
"electron-vite": "^2.0.0", | ||
"generic-names": "^4.0.0", | ||
"husky": "^9.0.11", | ||
|
@@ -82,7 +82,6 @@ | |
"react-router-dom": "^6.21.2", | ||
"rollup-plugin-copy": "^3.5.0", | ||
"systeminformation": "^5.22.7", | ||
"terser": "^5.30.0", | ||
"typescript": "^5.3.3", | ||
"utf-8-validate": "^6.0.3", | ||
"vite": "5.0.12", | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
const fs = require("fs") | ||
const path = require("path") | ||
|
||
module.exports = async function (context) { | ||
const appOutDir = context.appOutDir | ||
const localesDir = path.join(appOutDir, "locales") | ||
|
||
const localesToKeep = [ | ||
"en-US.pak", | ||
"zh-CN.pak", | ||
// 其他需要保留的语言包 | ||
] | ||
|
||
fs.readdir(localesDir, (err, files) => { | ||
if (err) throw err | ||
|
||
files.forEach((file) => { | ||
if (!localesToKeep.includes(file)) { | ||
fs.unlink(path.join(localesDir, file), (err) => { | ||
if (err) throw err | ||
// console.log(`Deleted locale: ${file}`) | ||
}) | ||
} | ||
}) | ||
}) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
import "./modules/baseConfig" | ||
import "./modules/MenuManger" | ||
import "./modules/ipcWin" | ||
import "./modules/store" | ||
import "./modules/autoLuanch" |
Oops, something went wrong.