Skip to content

Commit

Permalink
windows installer
Browse files Browse the repository at this point in the history
  • Loading branch information
omrirz committed Apr 3, 2020
1 parent c556c6e commit 24ae0ad
Show file tree
Hide file tree
Showing 6 changed files with 27 additions and 4 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@

[Mac installer](https://github.com/omrirz/kalk/releases/download/v.0.0.0/kalk-0.0.0.dmg)

[Windows installer](https://github.com/omrirz/kalk/releases/download/v.0.0.0/Kalk.Setup.0.0.0.exe)

## Usage

Expand Down
Binary file added build/icon.ico
Binary file not shown.
5 changes: 4 additions & 1 deletion main.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,10 @@ if (process.platform === 'win32') {
}

const getIconPath = () => {
const iconName = nativeTheme.shouldUseDarkColors ? 'icon_dark.png': 'icon.png';
let iconName = nativeTheme.shouldUseDarkColors ? 'icon_dark.png': 'icon.png';
if (process.platform === 'win32') {
iconName = 'icon_dark.png';
}
const iconPath = path.join(__dirname, 'src', 'assets', iconName);
return iconPath
}
Expand Down
23 changes: 21 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "kalk",
"name": "Kalk",
"version": "0.0.0",
"description": "Calculator for desktop",
"author": "omrirz",
Expand All @@ -13,13 +13,32 @@
"start": "electron .",
"clean": "rm -rf ./dist && rm -rf ./src/config.json",
"pack": "electron-builder --dir",
"dist": "npm run clean && electron-builder"
"dist:mac": "npm run clean && electron-builder --dir",
"dist:win": "npm run clean && electron-builder --win --x64"
},
"build": {
"appId": "BenderRodriguez",
"mac": {
"icon": "icon.icns",
"category": "Calculator"
},
"asar":false,
"directories": {
"output": "dist",
"buildResources": "build"
},
"win": {
"icon": "icon.ico",
"target": [
"nsis"
]
},
"nsis": {
"installerIcon": "icon.ico",
"uninstallerIcon": "icon.ico",
"runAfterFinish": true
}

},
"devDependencies": {
"asar": "^3.0.3",
Expand Down
Binary file removed src/assets/installBackground.png
Binary file not shown.
2 changes: 1 addition & 1 deletion src/config_manager.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ module.exports = class ConfigManager {
this.cfg.show_window_settings = true
} else {
this.cfg.mode = 'prod'
this.cfg.show_window = false
this.cfg.show_window = true
this.cfg.show_window_settings = false
}
}
Expand Down

0 comments on commit 24ae0ad

Please sign in to comment.