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

unpack/unpack-dir are broken #228

Open
Treverix opened this issue Feb 14, 2022 · 2 comments
Open

unpack/unpack-dir are broken #228

Treverix opened this issue Feb 14, 2022 · 2 comments

Comments

@Treverix
Copy link

Treverix commented Feb 14, 2022

I try to exclude node_modules/electron from the asar using this command, which I think, should do exactly this:

npx asar pack . app.asar --unpack-dir "node_modules/electron"

Now, when we look into the asar.app.unpacked folder, we find the files for node_modules/electron and also all files for all libraries like node_modules/electron* - for example, node_modules/electron-redux.

Then, when we do npx list app.asar, we see that node_modules/electron is still packaged (and the others also).

I expect, from the documentation, that it would just exclude that folder and not all, that simply start with the pattern, as that's what it says on the readme. And then, it actually does not exclude.

@Jaifroid
Copy link

Jaifroid commented Oct 9, 2022

Agreed, the documentation talks of "excluding" directories with --unpack-dir, but they are packed anyway and then duplicated in the unpacked directory.

@mmaietta
Copy link
Contributor

I've been trying to figure out the same thing. From what I can discern, it is creating a symlink between the file in the app.asar and the app.asar.unpacked. Seems to be the case as when I delete app.asar.unpacked folder, the electron app is no longer able to be run (even though app.asar shows the "files" embedded in the asar ----> symlink?)

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

3 participants