Snap package unpack edit then repack

its really painful process to build again from start it will re-download all parts then create snap. It would be great to debug plugs and snap services when unpack make changes then repack same snap and test it.

You can do that, but you can also use snap try on the prime directory, which lets you install the snap without even packing it.


Yes indeed. Try this: change the plugs and service definitions, and then run snapcraft prime again. It won’t rebuild everything (and will say that everything is already done, which is an issue), but if you then take a peek at the prime/meta/snap.yaml you’ll see that the changes you made actually applied-- the new plugs were copied in, the service name changed, etc.

Then, as @chipaca says, you can just run snap try prime and try the snap out in read/write mode.

1 Like

Thanks didn’t know try command though I’ve copied all files of parts to single folder then created a single part on yaml with dump plugin with source that folder so that It not download all files over again for sake of debugging app.

For anyone stumbled on this topic trying to find instructions on doing a manual snap unpack, edit, and repack, here’s one: Chromium configurable launch flags?