1

I am new to Electron and want to make (at first) a sample javascript change in the Slack Electron app. I am here on a Mac OSX:

/Applications/Slack.app/Contents/Resources

and run the following:

asar extract app.asar ~/Desktop/src

And then without even making a change run:

asar pack ~/Desktop/src app.asar

The "re-packed" file is significantly larger:

    -rw-r--r--   1 oliverwilliams  staff  28336486 Apr 21 03:25 app.asar
    -rw-r--r--   1 oliverwilliams  staff   8175963 Mar 21 13:26 app.asar.original

and Slack will not start. Reverting back to the original file, Slack runs again.

Obviously I need to crawl before I can walk. What needs to be done here?

Oliver Williams
  • 5,966
  • 7
  • 36
  • 78
  • Were you able to solve the problem? – Niklas Forst Oct 13 '22 at 10:00
  • I tried unpacking and re-packing an *.asar file (merely changing 4 small system tray icons in png format) in linux, using npm / npr extract/pack commands. The output file was far smaller (and broken of course). I had to use 7zip with asar plugin at the end. :-( – Sadi Nov 10 '22 at 14:11

0 Answers0