Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ide-electron项目可以打包windows平台吗 #68

Open
LuoTianStyle opened this issue Mar 30, 2023 · 2 comments
Open

ide-electron项目可以打包windows平台吗 #68

LuoTianStyle opened this issue Mar 30, 2023 · 2 comments

Comments

@LuoTianStyle
Copy link

我运行pnpm run pack:all的时候打包的项目中只有mac平台的安装包,怎么才可以打出windows的安装包呢

@yantze
Copy link
Member

yantze commented Mar 31, 2023

如果是 mac 系统,生成的就是 mac dmg,如果是 windows 系统环境会生成 windows exe 安装包

@yantze
Copy link
Member

yantze commented Mar 31, 2023

生成其它系统的安装包需要的条件比较多, 在 ide-electron 中 你可以改为 把 package.json scripts 字段
"pack:x64": "pnpm build && cross-env TARGET_ARCHES=x64 node build/pack.js",
改为
"pack:x64": "pnpm build && cross-env TARGET_PLATFORMS=win32 TARGET_ARCHES=x64 node build/pack.js",

但最后编译报错,因为 ide-elecron 用到了 Node.js 的 Addon ,需要 Windows 下才能编译出来

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants