mirror of
https://github.com/viarotel-org/escrcpy.git
synced 2024-11-15 03:07:41 +01:00
20 lines
585 B
JavaScript
20 lines
585 B
JavaScript
import { extraResolve } from '@electron/helpers/index.js'
|
|
import which from 'which'
|
|
|
|
export const getGnirehtetPath = () => {
|
|
switch (process.platform) {
|
|
// case 'darwin':
|
|
// return extraResolve('mac/gnirehtet/gnirehtet')
|
|
case 'win32':
|
|
return extraResolve('win/gnirehtet/gnirehtet.exe')
|
|
case 'linux':
|
|
return extraResolve('linux/gnirehtet/gnirehtet')
|
|
default:
|
|
return which.sync('gnirehtet', { nothrow: true })
|
|
}
|
|
}
|
|
|
|
export const gnirehtetPath = getGnirehtetPath()
|
|
|
|
export const gnirehtetApkPath = extraResolve('common/gnirehtet/gnirehtet.apk')
|