File tree 3 files changed +10
-24
lines changed
3 files changed +10
-24
lines changed Original file line number Diff line number Diff line change @@ -27,10 +27,10 @@ jobs:
27
27
- name : Install dependencies
28
28
run : npm install
29
29
30
- - name : Package the app for Linux, Windows, and macOS
30
+ - name : Package the app for Windows
31
31
run : |
32
- # Build for Linux, Windows, and macOS without publishing
33
- npx electron-builder --linux AppImage -- win nsis --mac dmg -p never
32
+ # Build for Windows without publishing
33
+ npx electron-builder --win nsis -p never
34
34
env :
35
35
GH_TOKEN : ${{ secrets.GH_TOKEN }} # Use your GitHub token with write permissions
36
36
40
40
tag : ' v${{ github.run_number }}'
41
41
name : ' TheCyberHUB Desktop Release v${{ github.run_number }}'
42
42
files : |
43
- dist/*.AppImage
44
43
dist/*.exe
45
- dist/*.dmg
46
44
env :
47
45
GH_TOKEN : ${{ secrets.GH_TOKEN }}
48
46
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change 9
9
"scripts" : {
10
10
"start" : " electron ." ,
11
11
"package" : " electron-builder" ,
12
- "build" : " npm run build:linux && npm run build:windows" ,
13
- "build:linux" : " electron-builder --linux AppImage -p never" ,
12
+ "build" : " npm run build:windows" ,
14
13
"build:windows" : " electron-builder --win nsis -p never" ,
15
- "build:mac" : " npm install --no-optional && electron-builder --mac -p never" ,
16
14
"lint" : " eslint ." ,
17
15
"test" : " echo \" No tests specified\" && exit 0"
18
16
},
23
21
" src/main.js"
24
22
],
25
23
"icon" : " dict/assets/th3cyb3rhub-fav.png" ,
26
- "mac" : {
27
- "category" : " public.app-category.utilities" ,
28
- "target" : [
29
- " dmg"
30
- ]
31
- },
32
- "linux" : {
33
- "target" : [
34
- " AppImage"
35
- ]
36
- },
37
24
"win" : {
38
25
"target" : [
39
26
" nsis"
Original file line number Diff line number Diff line change @@ -14,16 +14,17 @@ function createWindow() {
14
14
win . loadFile ( path . join ( __dirname , '../dist/index.html' ) ) ;
15
15
}
16
16
17
- app . whenReady ( ) . then ( createWindow ) ;
18
-
17
+ // Quit the application when all windows are closed
19
18
app . on ( 'window-all-closed' , ( ) => {
20
- if ( process . platform !== 'darwin' ) {
21
- app . quit ( ) ;
22
- }
19
+ app . quit ( ) ;
23
20
} ) ;
24
21
22
+ // Create a window when the application is activated
25
23
app . on ( 'activate' , ( ) => {
26
24
if ( BrowserWindow . getAllWindows ( ) . length === 0 ) {
27
25
createWindow ( ) ;
28
26
}
29
27
} ) ;
28
+
29
+ // Start the application and create the window
30
+ app . whenReady ( ) . then ( createWindow ) ;
You can’t perform that action at this time.
0 commit comments