Skip to content

OSS Brower问题答疑,希望能帮到你! #510

@MrSSai

Description

@MrSSai

以下内容在Ubuntu20.04上运行测试过,可打包生成exe程序

  1. 启动oss-browser步骤
# 运行
1. git clone https://github.com/aliyun/oss-browser.git
2. cd oss-browser
3. make i
4. make build
5. make run

# 打包
1. cp -r node_modules dist/
2. make all
  1. 推荐使用Ubuntu18.04Ubuntu20.04系统,Ubuntu23.04系统移除了libgconf-2-4.so文件,导致项目不能运行。node使用v8.2.1版本,推荐使用nvm管理nodenvm 安装脚本:https://github.com/nvm-sh/nvm/blob/master/install.sh
  2. Ubuntu18.04Ubuntu20.04都需要安装libgconf-2-4。安装命令:sudo apt install libgconf-2-4 -y
  3. make i安装依赖慢,可以使用npm install --registry=https://registry.npmmirror.com 替代make i
  4. Ubuntu20.04需要安装wine,安装方法在 技术|如何在 Ubuntu 中安装 Wine (linux.cn)
  5. 单击 OSS Browser 工具左上角图标连续 10 次弹出调试面板
  6. 开发模式运行, command+option+i 可用打开调试界面, winlinuxF12.
  7. ctrl+r是刷新页面
  8. 如果启动时白屏、显示和后端接口断开连接。可点击view->reload刷新页面
    需要将main.js中的win.setMenuBarVisibility(false);改为win.setMenuBarVisibility(true);)
    ctrl+r刷新来解决
  9. 打包命令(尽可在Ubuntu18.04打包成功,Ubuntu20.04打win64包报错缺少wine[需要安装wine]:make win64 # 打包win64程序, 可选: mac, linux64, linux32, win32, win64, all
  10. 打包输出的路径是项目目录的build目录
  11. 不要在distnpm i。否则在根目录make run就会报错,除非把distnode_modules目录删除,可以将根目录下的node_modules复制到dist目录一份
  12. 打包前将根目录下的node_modules目录复制到dist目录一份,不然打包生成的exe启动会报electron-log错误

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions