我已经创建了 electron 桌面应用,并使用电子生成器.
I have created a electron desktop app and created a installer using electron-builder.
现在我想尝试像 customInstall 和 customUnInstall
我的 installer.nsh 文件是
!macro customInstall MessageBox MB_OK "Test output 1" !macroend !macro customUnInstall MessageBox MB_OK "Test output 2" !macroend我的 electron-builder 配置是
"build": { "nsis": { "include": "installer.nsh" }, "mac": { "icon": "build/icon.png" }, "win": { "icon": "build/icon.png" } }但这对我不起作用.我已经通过引入错误来确认 installer.nsh 是否可以正常工作.我缺少使它正常工作的东西吗?
But this is not working for me. I have confirmed that installer.nsh is working by introducing error in that. What I am missing to make it working?
推荐答案目前,实际上一切正常.
Actually everything is working fine at this moment.
您的宏 customInstall 和 customUnInstall 定义正确,但是没有从任何地方调用它们.
Your macros customInstall and customUnInstall are defined correctly, but they are not called from any place.
只需从相应的部分/功能/位置/情况/等调用.
Simply call them from appropriate section/function/place/situation/etc.
它们的执行完全取决于您,不会从脚本中自动调用它们.
Their execution depends entirely on you, there are no automatic call of them from script.
更多推荐
电子生成器自定义NSIS包含脚本宏不起作用
发布评论