Skip to content
This repository has been archived by the owner on Aug 4, 2022. It is now read-only.

【建议】app.zip文件能用asar压缩在发布嘛? #29

Closed
Keene-Chen opened this issue Jul 29, 2021 · 1 comment
Closed

【建议】app.zip文件能用asar压缩在发布嘛? #29

Keene-Chen opened this issue Jul 29, 2021 · 1 comment

Comments

@Keene-Chen
Copy link

建议用asar工具打下包,每次下载解压会很长时间的,node_modules太耗时间了

  1. npm install -g asar
  2. asar p .\app\ app.asar
$asar -h
Usage: asar [options] [command]

Manipulate asar archive files

Options:
  -V, --version                         output the version number
  -h, --help                            display help for command

Commands:
  pack|p [options] <dir> <output>       create asar archive
  list|l [options] <archive>            list files of asar archive
  extract-file|ef <archive> <filename>  extract one file from archive
  extract|e <archive> <dest>            extract archive
  *
  help [command]                        display help for command

经过测试打包后功能都正常使用,当然我没有时间深入研究打包和不打包具体区别只是为了替换方便,望采纳!

@hlmd
Copy link
Owner

hlmd commented Jul 30, 2021

app.zip 是Mac、Windows、Linux通用的, 而asar只有Windows

@hlmd hlmd closed this as completed Jul 30, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants