mirror of
https://github.com/bitwarden/browser.git
synced 2024-11-22 11:45:59 +01:00
dont sign libs
This commit is contained in:
parent
701099a122
commit
48ba771db7
44
gulpfile.js
44
gulpfile.js
@ -179,7 +179,6 @@ function distSafariDmg(cb) {
|
||||
function distSafariApp(cb, subBuildPath, devId) {
|
||||
const buildPath = paths.dist + 'Safari/' + subBuildPath + '/';
|
||||
const builtAppexPath = buildPath + 'build/Release/safari.appex';
|
||||
const builtAppexFrameworkPath = buildPath + 'build/Release/safari.appex/Contents/Frameworks/';
|
||||
const entitlementsPath = paths.safari + 'safari/safari.entitlements';
|
||||
|
||||
return del([buildPath + '**/*'])
|
||||
@ -195,35 +194,30 @@ function distSafariApp(cb, subBuildPath, devId) {
|
||||
stdOutProc(proc);
|
||||
return new Promise((resolve) => proc.on('close', resolve));
|
||||
}).then(() => {
|
||||
const isMas = subBuildPath == 'mas';
|
||||
const libs = fs.readdirSync(builtAppexFrameworkPath).filter((p) => p.endsWith('.dylib'))
|
||||
.map((p) => builtAppexFrameworkPath + p);
|
||||
const allItems = isMas ? [builtAppexPath] : [...builtAppexPath, ...libs];
|
||||
const promises = [];
|
||||
allItems.forEach((i) => {
|
||||
const args1 = [
|
||||
var args = subBuildPath === 'mas' ?
|
||||
[
|
||||
'--verbose',
|
||||
'--force'];
|
||||
const argsHardRuntime = [
|
||||
'-o',
|
||||
'runtime'];
|
||||
const args2 = [
|
||||
'--force',
|
||||
'--sign',
|
||||
devId,
|
||||
'--entitlements',
|
||||
entitlementsPath,
|
||||
i];
|
||||
let args = [];
|
||||
if (isMas) {
|
||||
args = [...args1, ...args2];
|
||||
} else {
|
||||
args = [...args1, ...argsHardRuntime, ...args2];
|
||||
}
|
||||
const proc = child.spawn('codesign', args);
|
||||
stdOutProc(proc);
|
||||
promises.push(new Promise((resolve) => proc.on('close', resolve)));
|
||||
});
|
||||
return Promise.all(promises);
|
||||
builtAppexPath
|
||||
] :
|
||||
[
|
||||
'--verbose',
|
||||
'--force',
|
||||
'-o',
|
||||
'runtime',
|
||||
'--sign',
|
||||
devId,
|
||||
'--entitlements',
|
||||
entitlementsPath,
|
||||
builtAppexPath
|
||||
];
|
||||
const proc = child.spawn('codesign', args);
|
||||
stdOutProc(proc);
|
||||
return new Promise((resolve) => proc.on('close', resolve));
|
||||
}).then(() => {
|
||||
return cb;
|
||||
}, () => {
|
||||
|
Loading…
Reference in New Issue
Block a user