diff --git a/electron/events/handles/index.js b/electron/events/handles/index.js index 6af2f4e..e885d8c 100644 --- a/electron/events/handles/index.js +++ b/electron/events/handles/index.js @@ -7,7 +7,7 @@ export default (mainWindow) => { ipcMain.handle( 'show-open-dialog', - async (event, { preset = '', ...options } = {}) => { + async (_, { preset = '', ...options } = {}) => { // console.log('options', options) const res = await dialog .showOpenDialog(options) @@ -33,17 +33,17 @@ export default (mainWindow) => { }, ) - ipcMain.handle('open-path', async (event, pathValue) => { + ipcMain.handle('open-path', async (_, pathValue) => { return shell.openPath(pathValue) }) - ipcMain.handle('show-item-in-folder', async (event, filePath) => { + ipcMain.handle('show-item-in-folder', async (_, filePath) => { return shell.showItemInFolder(filePath) }) ipcMain.handle( 'show-save-dialog', - async (event, { filePath = '', ...options } = {}) => { + async (_, { filePath = '', ...options } = {}) => { const res = await dialog .showSaveDialog({ ...options, diff --git a/electron/exposes/adbkit/index.js b/electron/exposes/adbkit/index.js index 49ce96c..3450e1e 100644 --- a/electron/exposes/adbkit/index.js +++ b/electron/exposes/adbkit/index.js @@ -148,6 +148,8 @@ const watch = async (callback) => { export default () => { const binPath = appStore.get('common.adbPath') || adbPath + console.log('adb.binPath', binPath) + client = Adb.createClient({ bin: binPath, }) diff --git a/electron/exposes/scrcpy/index.js b/electron/exposes/scrcpy/index.js index 69b8ef6..9c6137a 100644 --- a/electron/exposes/scrcpy/index.js +++ b/electron/exposes/scrcpy/index.js @@ -7,8 +7,11 @@ const shell = async (command, { stdout, stderr } = {}) => { const ADB = appStore.get('common.adbPath') || adbPath const args = command.split(' ') + console.log('scrcpy.shell.spawnPath', spawnPath) + console.log('scrcpy.shell.ADB', ADB) + const scrcpyProcess = spawn(`"${spawnPath}"`, args, { - env: { ...process.env, ADB: `"${ADB}"` }, + env: { ...process.env, ADB }, shell: true, encoding: 'utf8', }) diff --git a/src/components/Preference/index.vue b/src/components/Preference/index.vue index 3a909aa..d4b347f 100644 --- a/src/components/Preference/index.vue +++ b/src/components/Preference/index.vue @@ -195,7 +195,7 @@