sign
This commit is contained in:
parent
c2e30c5915
commit
9358bd1e80
@ -57,10 +57,13 @@ function buildPortableApp() {
|
||||
// 完全删除签名环境变量
|
||||
delete process.env.WIN_CSC_LINK;
|
||||
delete process.env.WIN_CSC_KEY_PASSWORD;
|
||||
// 新增:设置环境变量明确禁用签名
|
||||
process.env.ELECTRON_BUILDER_SKIP_NOTARIZATION = 'true';
|
||||
process.env.ELECTRON_SKIP_NOTARIZE = 'true';
|
||||
|
||||
// 使用最基本的命令行参数,让配置完全由vue.config.js控制
|
||||
// 使用基础命令行参数,同时添加额外的签名禁用参数
|
||||
execSync(
|
||||
'npm run electron:build -- --win portable --ia32 --x64 --publish never',
|
||||
'npm run electron:build -- --win portable --ia32 --x64 --publish never --no-sign',
|
||||
{ stdio: 'inherit' }
|
||||
);
|
||||
|
||||
|
@ -57,5 +57,11 @@
|
||||
"> 1%",
|
||||
"last 2 versions",
|
||||
"not dead"
|
||||
]
|
||||
],
|
||||
"build": {
|
||||
"win": {
|
||||
"sign": false
|
||||
},
|
||||
"forceCodeSigning": false
|
||||
}
|
||||
}
|
||||
|
@ -70,9 +70,11 @@ module.exports = {
|
||||
],
|
||||
// 图标设置
|
||||
icon: "public/favicon.ico",
|
||||
// 签名设置
|
||||
signingHashAlgorithms: ['sha256'],
|
||||
sign: false, // 明确禁用签名
|
||||
// 明确禁用签名的多种配置
|
||||
sign: false,
|
||||
signingHashAlgorithms: [],
|
||||
certificateFile: null,
|
||||
certificatePassword: null,
|
||||
|
||||
// 额外资源配置
|
||||
extraResources: [
|
||||
@ -97,14 +99,17 @@ module.exports = {
|
||||
// 便携应用特定配置
|
||||
portable: {
|
||||
artifactName: "统计技能考试系统_便携版_${version}_${arch}.exe",
|
||||
// 只保留支持的属性,移除target属性
|
||||
},
|
||||
|
||||
// 发布设置
|
||||
publish: {
|
||||
provider: 'generic',
|
||||
url: 'https://example.com/',
|
||||
}
|
||||
},
|
||||
|
||||
// 全局禁用签名配置
|
||||
forceCodeSigning: false,
|
||||
asar: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user