added configurations electron

This commit is contained in:
PhilReact 2024-10-31 16:44:55 +02:00
parent 839dd30ee1
commit a9d6dd3465
9 changed files with 3168 additions and 58 deletions

BIN
electron/assets/qort.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

BIN
electron/assets/qortal.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 158 KiB

View File

@ -1,5 +1,5 @@
{ {
"appId": "com.yourdoamnin.yourapp", "appId": "com.yourdomain.yourapp",
"directories": { "directories": {
"buildResources": "resources" "buildResources": "resources"
}, },
@ -9,9 +9,6 @@
"capacitor.config.*", "capacitor.config.*",
"app/**/*" "app/**/*"
], ],
"publish": {
"provider": "github"
},
"nsis": { "nsis": {
"allowElevation": true, "allowElevation": true,
"oneClick": false, "oneClick": false,
@ -21,8 +18,14 @@
"target": "nsis", "target": "nsis",
"icon": "assets/appIcon.ico" "icon": "assets/appIcon.ico"
}, },
"linux": {
"target": ["AppImage"],
"category": "Utility", // Set a specific Linux category here
"executableName": "Qortal",
"icon": "assets/qortal.png"
},
"mac": { "mac": {
"category": "your.app.category.type", "category": "your.app.category.type",
"target": "dmg" "target": "dmg"
} }
} }

View File

@ -10,7 +10,7 @@
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@capacitor-community/electron": "^5.0.0", "@capacitor-community/electron": "^5.0.0",
"chokidar": "~3.5.3", "chokidar": "^3.6.0",
"electron-is-dev": "~2.0.0", "electron-is-dev": "~2.0.0",
"electron-serve": "~1.1.0", "electron-serve": "~1.1.0",
"electron-unhandled": "~4.0.1", "electron-unhandled": "~4.0.1",
@ -1566,16 +1566,9 @@
} }
}, },
"node_modules/chokidar": { "node_modules/chokidar": {
"version": "3.5.3", "version": "3.6.0",
"resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz", "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.6.0.tgz",
"integrity": "sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==", "integrity": "sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==",
"funding": [
{
"type": "individual",
"url": "https://paulmillr.com/funding/"
}
],
"license": "MIT",
"dependencies": { "dependencies": {
"anymatch": "~3.1.2", "anymatch": "~3.1.2",
"braces": "~3.0.2", "braces": "~3.0.2",
@ -1588,6 +1581,9 @@
"engines": { "engines": {
"node": ">= 8.10.0" "node": ">= 8.10.0"
}, },
"funding": {
"url": "https://paulmillr.com/funding/"
},
"optionalDependencies": { "optionalDependencies": {
"fsevents": "~2.3.2" "fsevents": "~2.3.2"
} }

View File

@ -21,7 +21,7 @@
}, },
"dependencies": { "dependencies": {
"@capacitor-community/electron": "^5.0.0", "@capacitor-community/electron": "^5.0.0",
"chokidar": "~3.5.3", "chokidar": "^3.6.0",
"electron-is-dev": "~2.0.0", "electron-is-dev": "~2.0.0",
"electron-serve": "~1.1.0", "electron-serve": "~1.1.0",
"electron-unhandled": "~4.0.1", "electron-unhandled": "~4.0.1",

View File

@ -46,7 +46,7 @@ if (electronIsDev) {
// Initialize our app, build windows, and load content. // Initialize our app, build windows, and load content.
await myCapacitorApp.init(); await myCapacitorApp.init();
// Check for updates if we are in a packaged app. // Check for updates if we are in a packaged app.
autoUpdater.checkForUpdatesAndNotify(); // autoUpdater.checkForUpdatesAndNotify();
})(); })();
// Handle when all of our windows are close (platforms have their own expectations). // Handle when all of our windows are close (platforms have their own expectations).

View File

@ -10,6 +10,7 @@
"esModuleInterop": true, "esModuleInterop": true,
"typeRoots": ["./node_modules/@types"], "typeRoots": ["./node_modules/@types"],
"allowJs": true, "allowJs": true,
"rootDir": "." "rootDir": ".",
"skipLibCheck": true
} }
} }

3180
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -9,10 +9,7 @@
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0", "lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
"preview": "vite preview", "preview": "vite preview",
"test": "vitest", "test": "vitest",
"coverage": "vitest run --coverage", "coverage": "vitest run --coverage"
"electron:mac": "electron-packager ./electron Qortal --overwrite --platform=darwin --arch=x64 --prune=true --out=release-builds",
"electron:win": "electron-packager ./electron Qortal --overwrite --asar=true --platform=win32 --arch=ia32 --prune=true --out=release-builds --version-string.CompanyName=CE --version-string.FileDescription=CE --version-string.ProductName='Qortal Electron App'",
"electron:linux": "electron-packager ./electron Qortal --overwrite --platform=linux --arch=x64 --prune=true --out=release-builds --executable-name=qortal-app --version-string.CompanyName=CE --version-string.FileDescription=CE --version-string.ProductName='Qortal Electron App'"
}, },
"dependencies": { "dependencies": {
"@capacitor-community/electron": "^5.0.1", "@capacitor-community/electron": "^5.0.1",
@ -49,6 +46,7 @@
"asmcrypto.js": "2.3.2", "asmcrypto.js": "2.3.2",
"bcryptjs": "2.4.3", "bcryptjs": "2.4.3",
"buffer": "6.0.3", "buffer": "6.0.3",
"chokidar": "^3.6.0",
"compressorjs": "^1.2.1", "compressorjs": "^1.2.1",
"cordova-plugin-android-permissions": "^1.1.5", "cordova-plugin-android-permissions": "^1.1.5",
"cordova-plugin-file": "^8.1.1", "cordova-plugin-file": "^8.1.1",
@ -94,6 +92,8 @@
"@typescript-eslint/eslint-plugin": "^7.1.1", "@typescript-eslint/eslint-plugin": "^7.1.1",
"@typescript-eslint/parser": "^7.1.1", "@typescript-eslint/parser": "^7.1.1",
"@vitejs/plugin-react": "^4.2.1", "@vitejs/plugin-react": "^4.2.1",
"electron": "^33.0.2",
"electron-builder": "^25.1.8",
"esbuild-plugin-react-virtualized": "^1.0.4", "esbuild-plugin-react-virtualized": "^1.0.4",
"eslint": "^8.57.0", "eslint": "^8.57.0",
"eslint-plugin-react-hooks": "^4.6.0", "eslint-plugin-react-hooks": "^4.6.0",