mirror of
https://github.com/balena-io/etcher.git
synced 2025-07-24 11:46:31 +00:00
patch: fix sudo for mac catalina and above
This commit is contained in:
parent
a61652a0b8
commit
50adc32356
@ -41,6 +41,10 @@ const config: ForgeConfig = {
|
||||
appCopyright: 'Copyright 2016-2023 Balena Ltd',
|
||||
darwinDarkModeSupport: true,
|
||||
protocols: [{ name: 'etcher', schemes: ['etcher'] }],
|
||||
extraResource: [
|
||||
"lib/shared/catalina-sudo/sudo-askpass.osascript-zh.js",
|
||||
"lib/shared/catalina-sudo/sudo-askpass.osascript-en.js"
|
||||
],
|
||||
osxSign: {
|
||||
optionsForFile: () => ({
|
||||
entitlements: './entitlements.mac.plist',
|
||||
|
@ -19,7 +19,6 @@ import { join } from 'path';
|
||||
import { env } from 'process';
|
||||
import { promisify } from 'util';
|
||||
|
||||
import { getAppPath } from '../get-app-path';
|
||||
import { supportedLocales } from '../../gui/app/i18n';
|
||||
|
||||
const execFileAsync = promisify(execFile);
|
||||
@ -48,8 +47,7 @@ export async function sudo(
|
||||
env: {
|
||||
PATH: env.PATH,
|
||||
SUDO_ASKPASS: join(
|
||||
getAppPath(),
|
||||
__dirname,
|
||||
process.resourcesPath,
|
||||
`sudo-askpass.osascript-${lang}.js`,
|
||||
),
|
||||
},
|
||||
|
Loading…
x
Reference in New Issue
Block a user