Skip to content

Commit

Permalink
Fix jat-52 for prod
Browse files Browse the repository at this point in the history
xenown committed Jun 9, 2022
1 parent 1ed5021 commit 1b0841e
Showing 3 changed files with 20 additions and 1 deletion.
9 changes: 8 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -240,7 +240,14 @@
"output": "release/build"
},
"extraResources": [
"./assets/**"
"./assets/**",
{
"from": "node_modules/regedit/vbs",
"to": "vbs",
"filter": [
"**/*"
]
}
],
"publish": {
"provider": "github",
1 change: 1 addition & 0 deletions src/main/main.ts
Original file line number Diff line number Diff line change
@@ -120,6 +120,7 @@ const createMainWindow = async () => {
: path.join(__dirname, '../../.erb/dll/preload.js'),
},
});
mainWindow.webContents.openDevTools();

mainWindow.loadURL(resolveHtmlPath('index.html'));

11 changes: 11 additions & 0 deletions src/main/registry.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
import path = require('path');
import { app } from 'electron';

const regedit = require('regedit').promisified;

const regeditNonPromise = require('regedit');

const vbsDirectory = path.join(
path.dirname(app.getPath('exe')),
'./resources/vbs'
);
regeditNonPromise.setExternalVBSLocation(vbsDirectory);

const isPeaceInstalled = async () => {
const registryKey =
'HKLM\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall';

0 comments on commit 1b0841e

Please sign in to comment.