mirror of
https://github.com/Eugeny/tabby.git
synced 2025-07-20 02:18:01 +00:00
electron 11 cleanup
This commit is contained in:
@@ -1,22 +0,0 @@
|
||||
#!/usr/bin/env node
|
||||
const builder = require('electron-builder').build
|
||||
const vars = require('./vars')
|
||||
const fs = require('fs')
|
||||
const signHook = require('../build/mac/afterSignHook')
|
||||
|
||||
const isTag = (process.env.GITHUB_REF || '').startsWith('refs/tags/')
|
||||
|
||||
builder({
|
||||
dir: true,
|
||||
mac: ['pkg', 'zip'],
|
||||
arm64: true,
|
||||
config: {
|
||||
extraMetadata: {
|
||||
version: vars.version,
|
||||
},
|
||||
},
|
||||
publish: isTag ? 'always' : 'onTag',
|
||||
}).catch(e => {
|
||||
console.error(e)
|
||||
process.exit(1)
|
||||
})
|
@@ -9,6 +9,7 @@ const isTag = (process.env.GITHUB_REF || '').startsWith('refs/tags/')
|
||||
builder({
|
||||
dir: true,
|
||||
mac: ['pkg', 'zip'],
|
||||
arm64: (process.env.ARCH ?? process.arch) === 'arm64',
|
||||
config: {
|
||||
extraMetadata: {
|
||||
version: vars.version,
|
||||
|
@@ -8,6 +8,7 @@ for (let dir of ['app', 'terminus-core', 'terminus-ssh', 'terminus-terminal']) {
|
||||
const build = rebuild({
|
||||
buildPath: path.resolve(__dirname, '../' + dir),
|
||||
electronVersion: vars.electronVersion,
|
||||
arch: process.env.ARCH ?? process.arch,
|
||||
force: true,
|
||||
})
|
||||
build.catch(e => {
|
||||
|
@@ -20,8 +20,6 @@ vars.builtinPlugins.forEach(plugin => {
|
||||
sh.cd('..')
|
||||
})
|
||||
|
||||
sh.cp('binding.gyp_hack', "app/node_modules/@terminus-term/node-pty/binding.gyp")
|
||||
|
||||
if (['darwin', 'linux'].includes(process.platform)) {
|
||||
sh.cd('node_modules')
|
||||
for (let x of vars.builtinPlugins) {
|
||||
|
@@ -1,7 +0,0 @@
|
||||
#This script creates local release for macos
|
||||
|
||||
./scripts/install-deps.js
|
||||
./scripts/build-native.js
|
||||
./scripts/prepackage-plugins.js
|
||||
npm run build
|
||||
./scripts/build-macos-arm64.js
|
@@ -6,9 +6,6 @@ const fs = require('fs')
|
||||
const vars = require('./vars')
|
||||
const log = require('npmlog')
|
||||
|
||||
const localBinPath = path.resolve(__dirname, '../node_modules/.bin');
|
||||
const npx = `${localBinPath}/npx`;
|
||||
|
||||
let target = path.resolve(__dirname, '../builtin-plugins')
|
||||
sh.mkdir('-p', target)
|
||||
fs.writeFileSync(path.join(target, 'package.json'), '{}')
|
||||
@@ -18,13 +15,17 @@ vars.builtinPlugins.forEach(plugin => {
|
||||
sh.cp('-r', path.join('..', plugin), '.')
|
||||
sh.rm('-rf', path.join(plugin, 'node_modules'))
|
||||
sh.cd(plugin)
|
||||
//sh.exec(`npm install --only=prod`)
|
||||
sh.exec(`${npx} yarn install --force`)
|
||||
sh.exec(`yarn install --force --production`)
|
||||
|
||||
|
||||
|
||||
log.info('rebuild', 'native')
|
||||
if (fs.existsSync('node_modules')) {
|
||||
rebuild(path.resolve('.'), vars.electronVersion, process.arch, [], true)
|
||||
rebuild({
|
||||
buildPath: path.resolve('.'),
|
||||
electronVersion: vars.electronVersion,
|
||||
arch: process.env.ARCH ?? process.arch,
|
||||
force: true,
|
||||
})
|
||||
}
|
||||
sh.cd('..')
|
||||
})
|
||||
|
Reference in New Issue
Block a user