mirror of
https://github.com/hydralauncher/hydra.git
synced 2025-01-23 21:44:55 +03:00
Merge pull request #136 from hydralauncher/fix/update-fastlist-location-after-electron-build-migration
fix: update fastlist directory
This commit is contained in:
commit
7c7d390b5b
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,6 +1,7 @@
|
||||
.vscode
|
||||
node_modules
|
||||
hydra-download-manager
|
||||
fastlist.exe
|
||||
__pycache__
|
||||
dist
|
||||
out
|
||||
|
@ -5,6 +5,7 @@ directories:
|
||||
extraResources:
|
||||
- hydra-download-manager
|
||||
- hydra.db
|
||||
- fastlist.exe
|
||||
files:
|
||||
- "!**/.vscode/*"
|
||||
- "!src/*"
|
||||
|
@ -1,12 +1,8 @@
|
||||
const fs = require("fs");
|
||||
|
||||
if (process.platform === "win32") {
|
||||
if (!fs.existsSync("resources/dist")) {
|
||||
fs.mkdirSync("resources/dist");
|
||||
}
|
||||
|
||||
fs.copyFileSync(
|
||||
"node_modules/ps-list/vendor/fastlist-0.3.0-x64.exe",
|
||||
"resources/dist/fastlist.exe"
|
||||
"fastlist.exe"
|
||||
);
|
||||
}
|
||||
|
@ -10,8 +10,8 @@ const execFile = promisify(childProcess.execFile);
|
||||
export const getProcesses = async () => {
|
||||
if (process.platform == "win32") {
|
||||
const binaryPath = app.isPackaged
|
||||
? path.join(process.resourcesPath, "dist", "fastlist.exe")
|
||||
: path.join(__dirname, "..", "..", "resources", "dist", "fastlist.exe");
|
||||
? path.join(process.resourcesPath, "fastlist.exe")
|
||||
: path.join(__dirname, "..", "..", "fastlist.exe");
|
||||
|
||||
const { stdout } = await execFile(binaryPath, {
|
||||
maxBuffer: TEN_MEGABYTES,
|
||||
|
Loading…
Reference in New Issue
Block a user