This repository has been archived on 2023-08-30. You can view files and clone it, but cannot push or open issues/pull-requests.
appcat
/
sonist
Archived
1
0
Fork 0

增加打包配置

2.x
宇天 2019-01-19 04:33:34 +08:00
parent e4b6479da5
commit 1aa8edb82e
5 changed files with 52 additions and 7 deletions

3
.gitignore vendored
View File

@ -7,6 +7,9 @@
.Trashes
build
build/**
node_modules
node_modules/**

BIN
icons/app.icns Normal file

Binary file not shown.

View File

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 17 KiB

View File

@ -1,18 +1,60 @@
{
"name": "sonist",
"version": "0.1.0",
"name": "Sonist",
"version": "0.9.0",
"description": "Music Player",
"main": "src/main.js",
"scripts": {
"start": "electron ."
"start": "electron .",
"pack": "electron-builder"
},
"author": "yutent",
"license": "MIT",
"dependencies": {
"crypto.js": "^1.1.6",
"crypto.js": "^1.2.0",
"iofs": "^1.1.0"
},
"devDependencies": {
"electron": "^4.0.0"
"electron": "^4.0.0",
"electron-builder": "^20.38.5"
},
"build": {
"appId": "cc.doui.sonist",
"productName": "Sonist",
"copyright": "Copyright © year ${author}",
"directories": {
"output": "build"
},
"files": ["src/**/*", "node_modules/iofs/*", "node_modules/crypto.js/*"],
"mac": {
"category": "public.app-category.music",
"target": "dmg",
"icon": "icons/app.icns"
},
"linux": {
"category": "AudioVideo;Audio;Player;Music",
"target": [
{
"target": "deb",
"arch": "x64"
},
{
"target": "AppImage",
"arch": "x64"
}
],
"icon": "icons/app.png"
},
"deb": {
"depends": [
"gconf2",
"gconf-service",
"libnotify4",
"libappindicator1",
"libxtst6",
"libnss3",
"ffprobe",
"ffmpeg"
]
}
}
}

View File

@ -57,7 +57,7 @@ function createWindow() {
height: 640,
frame: false,
resizable: false,
icon: './src/images/app.png',
icon: path.resolve(ROOT, './images/app.png'),
webPreferences: {
webSecurity: false,
experimentalFeatures: true
@ -88,7 +88,7 @@ app.on('ready', () => {
cb({ data: buf, mimeType: MIME_TYPES[ext] })
})
tray = new Tray('./src/images/trays/trayTemplate.png')
tray = new Tray(path.resolve(ROOT, './images/trays/trayTemplate.png'))
tray.on('click', _ => {
win.show()