mirror of
https://github.com/bitwarden/browser
synced 2025-12-12 14:23:32 +00:00
dist safari dmg and mas
This commit is contained in:
36
gulpfile.js
36
gulpfile.js
@@ -168,13 +168,18 @@ function edgeCopyAssets(source, dest) {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function distSafari(cb) {
|
function distSafariMas(cb) {
|
||||||
const buildPath = paths.dist + 'Safari/';
|
return distSafariApp(cb, 'mas', '3rd Party Mac Developer Application: 8bit Solutions LLC');
|
||||||
|
}
|
||||||
|
|
||||||
|
function distSafariDmg(cb) {
|
||||||
|
return distSafariApp(cb, 'dmg', 'Developer ID Application: 8bit Solutions LLC');
|
||||||
|
}
|
||||||
|
|
||||||
|
function distSafariApp(cb, subBuildPath, devId) {
|
||||||
|
const buildPath = paths.dist + 'Safari/' + subBuildPath + '/';
|
||||||
const builtAppexPath = buildPath + 'build/Release/safari.appex';
|
const builtAppexPath = buildPath + 'build/Release/safari.appex';
|
||||||
const builtSafariCodeSigPath = builtAppexPath + '/Contents/_CodeSignature';
|
|
||||||
const builtSafariExecutablePath = builtAppexPath + '/Contents/MacOS/safari';
|
|
||||||
const entitlementsPath = paths.safari + 'safari/safari.entitlements';
|
const entitlementsPath = paths.safari + 'safari/safari.entitlements';
|
||||||
const devId = 'Developer ID Application: 8bit Solutions LLC';
|
|
||||||
|
|
||||||
return del([buildPath + '**/*'])
|
return del([buildPath + '**/*'])
|
||||||
.then(() => safariCopyAssets(paths.safari + '**/*', buildPath))
|
.then(() => safariCopyAssets(paths.safari + '**/*', buildPath))
|
||||||
@@ -188,25 +193,6 @@ function distSafari(cb) {
|
|||||||
'Release']);
|
'Release']);
|
||||||
stdOutProc(proc);
|
stdOutProc(proc);
|
||||||
return new Promise((resolve) => proc.on('close', resolve));
|
return new Promise((resolve) => proc.on('close', resolve));
|
||||||
}).then(() => {
|
|
||||||
const proc = child.spawn('rm', [
|
|
||||||
'-rf',
|
|
||||||
builtSafariCodeSigPath]);
|
|
||||||
stdOutProc(proc);
|
|
||||||
return new Promise((resolve) => proc.on('close', resolve));
|
|
||||||
}).then(() => {
|
|
||||||
const proc = child.spawn('codesign', [
|
|
||||||
'--verbose',
|
|
||||||
'--force',
|
|
||||||
'-o',
|
|
||||||
'runtime',
|
|
||||||
'--sign',
|
|
||||||
devId,
|
|
||||||
'--entitlements',
|
|
||||||
entitlementsPath,
|
|
||||||
builtSafariExecutablePath]);
|
|
||||||
stdOutProc(proc);
|
|
||||||
return new Promise((resolve) => proc.on('close', resolve));
|
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
const proc = child.spawn('codesign', [
|
const proc = child.spawn('codesign', [
|
||||||
'--verbose',
|
'--verbose',
|
||||||
@@ -289,7 +275,7 @@ exports['dist:firefox'] = distFirefox;
|
|||||||
exports['dist:chrome'] = distChrome;
|
exports['dist:chrome'] = distChrome;
|
||||||
exports['dist:opera'] = distOpera;
|
exports['dist:opera'] = distOpera;
|
||||||
exports['dist:edge'] = distEdge;
|
exports['dist:edge'] = distEdge;
|
||||||
exports['dist:safari'] = distSafari;
|
exports['dist:safari'] = gulp.parallel(distSafariMas, distSafariDmg);
|
||||||
exports.dist = gulp.parallel(distFirefox, distChrome, distOpera, distEdge);
|
exports.dist = gulp.parallel(distFirefox, distChrome, distOpera, distEdge);
|
||||||
exports['ci:coverage'] = ciCoverage;
|
exports['ci:coverage'] = ciCoverage;
|
||||||
exports.ci = ciCoverage;
|
exports.ci = ciCoverage;
|
||||||
|
|||||||
Reference in New Issue
Block a user