How does snap store scripts in script pics?

it's literal magic, like how does it do that?

i thought this was the first topic with this tag but that was just a rendering glitch

By exporting the script as XML and putting it (seemingly URI-encoded) in the PNG using the format's iTXt chunks. I used exiftool to view it:


image

(in a hex editor:)
image

Oh hey CST, long time no see!

oh my God you have an account somewhere else, also hey you;re back