mirror of
https://github.com/wavetermdev/waveterm.git
synced 2025-01-02 18:39:05 +01:00
4ef921bdd1
* Add linux makers * missed some * remove eu-strip * blah * add description * remove v from version * add exec name * use bin * add bin to both * test flatpak * test adding dev dependencies * remove flatpak for now * add command to flatten directory structure * update package info * save rpm info * save work * add bin to packagerConfig * save work * okay let's see what happens * iterate array * test more * remove large * test * test * remove linux arm * test addl targets * add quiet to zip * revert dir flatten * remove pacman * add s3 bucket to electron-builder config * make dir * only copy artifacts * don't merge * zip recurse * blah * replace with electronupdater * make generic * fix * fix stuff * Update build-helper.yml * test fix * fix path * remove tree * messed up comment * remove touch * add platform name to artifact * remove license * remove forge * cleanup builder config * switch artifact name order * Remove darwin restriction on autoupdate * try adding back pacman * fix license * remove pacman again * rewrite scripts * add binary paths to builder * clean up * Update scripts * update interval and readme * remove flatpak and snap dependencies for now * upload with a wildcard * fix paths for addl binaries * add back blockmap * update release path * add newline * remove forge config * 2 small fixes - remove double cd for waveshell building, and remove GOARCH for wavesrv binary in dev mode
46 lines
1.3 KiB
JavaScript
46 lines
1.3 KiB
JavaScript
// Sign the app and binaries for macOS
|
|
|
|
const { signAsync } = require("@electron/osx-sign");
|
|
const path = require("path");
|
|
const fs = require("fs");
|
|
|
|
/**
|
|
* Sign the app and binaries for macOS
|
|
* @param {string} waveAppPath - Path to the Wave.app
|
|
* @returns {Promise<void>}
|
|
*/
|
|
async function signApp(waveAppPath) {
|
|
const binDirPath = path.resolve(waveAppPath, "Contents", "Resources", "app.asar.unpacked", "bin");
|
|
const binFilePaths = fs
|
|
.readdirSync(binDirPath, { recursive: true, withFileTypes: true })
|
|
.filter((f) => f.isFile())
|
|
.map((f) => path.resolve(binDirPath, f.path, f.name));
|
|
console.log("waveAppPath", waveAppPath);
|
|
console.log("binDirPath", binDirPath);
|
|
console.log("binFilePaths", binFilePaths);
|
|
return signAsync({
|
|
app: waveAppPath,
|
|
binaries: binFilePaths,
|
|
})
|
|
.then(() => {
|
|
console.log("signing success");
|
|
})
|
|
.catch((e) => {
|
|
console.log("signing error", e);
|
|
process.exit(1);
|
|
});
|
|
}
|
|
|
|
if (require.main === module) {
|
|
console.log("running osx-sign");
|
|
const waveAppPath = path.resolve(__dirname, "temp", "Wave.app");
|
|
(async () => {
|
|
await signApp(waveAppPath);
|
|
console.log("signing complete");
|
|
})();
|
|
}
|
|
|
|
module.exports = {
|
|
signApp,
|
|
};
|