From d952c2af10d60cc0f633492041f48668e682e17d Mon Sep 17 00:00:00 2001 From: Andrey Onishchenko Date: Thu, 4 Jul 2024 08:23:31 +0300 Subject: [PATCH] Fix repack --- patches/0003-Create-app-tray-icon.patch | 6 +++--- patches/0004-Fix-window-resize.patch | 2 +- repack.sh | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/patches/0003-Create-app-tray-icon.patch b/patches/0003-Create-app-tray-icon.patch index 2eef730..57db2b0 100644 --- a/patches/0003-Create-app-tray-icon.patch +++ b/patches/0003-Create-app-tray-icon.patch @@ -28,7 +28,7 @@ diff --git a/main/lib/createTray.js b/main/lib/createTray.js diff --git a/main/index.js b/main/index.js --- a/main/index.js +++ b/main/index.js -@@ -42,6 +42,9 @@ Logger_js_1.Logger.setupLogger(); +@@ -46,6 +46,9 @@ Logger_js_1.Logger.setupLogger(); (0, handleDeeplink_js_1.handleDeeplink)(window); (0, handleMetrikaRequests_js_1.handleMetrikaRequests)(window); (0, handleCrash_js_1.handleCrash)(); @@ -43,7 +43,7 @@ diff --git a/main/index.js b/main/index.js diff --git a/main/lib/handlers/handleWindowLifecycleEvents.js b/main/lib/handlers/handleWindowLifecycleEvents.js --- a/main/lib/handlers/handleWindowLifecycleEvents.js +++ b/main/lib/handlers/handleWindowLifecycleEvents.js -@@ -29,9 +29,8 @@ const handleWindowLifecycleEvents = (window) => { +@@ -28,9 +28,8 @@ const handleWindowLifecycleEvents = (window) => { state_js_1.state.willQuit = true; }); electron_1.app.on('window-all-closed', () => { @@ -55,7 +55,7 @@ diff --git a/main/lib/handlers/handleWindowLifecycleEvents.js b/main/lib/handler }); electron_1.app.on('browser-window-blur', () => { setBlurredTime(); -@@ -49,22 +48,11 @@ const handleWindowLifecycleEvents = (window) => { +@@ -51,22 +50,11 @@ const handleWindowLifecycleEvents = (window) => { checkAndUpdateApplicationData(window); }); window.on('close', (event) => { diff --git a/patches/0004-Fix-window-resize.patch b/patches/0004-Fix-window-resize.patch index 3aa647b..8ad7409 100644 --- a/patches/0004-Fix-window-resize.patch +++ b/patches/0004-Fix-window-resize.patch @@ -1,7 +1,7 @@ diff --git a/main/lib/createWindow.js b/main/lib/createWindow.js --- a/main/lib/createWindow.js +++ b/main/lib/createWindow.js -@@ -25,8 +25,6 @@ const createWindow = async () => { +@@ -45,8 +45,6 @@ const createWindow = async () => { x: 16, y: 10 }, diff --git a/repack.sh b/repack.sh index 64c00b1..1667876 100755 --- a/repack.sh +++ b/repack.sh @@ -84,7 +84,7 @@ done echo "Title Fixed" echo "Replacing Icons" -cp -drf "$SCRIPT_DIR/icons/." "./build/next-desktop/" +cp -drf "$SCRIPT_DIR/icons/." "./app/" echo "Replaced Icons" # applying patches @@ -131,7 +131,7 @@ echo "Packing" cd "$curdir" asar pack "$TEMPDIR/app" "$dst/yandex-music.asar" for ext in png svg; do - mv "$TEMPDIR/app/build/next-desktop/favicon.$ext" "$dst" + mv "$TEMPDIR/app/app/favicon.$ext" "$dst" done python "$SCRIPT_DIR/utility/extract_release_notes.py" "$TEMPDIR/app/main/translations/compiled/ru.json" "$dst/release_notes.json"