It's not that weird. Most of Office and Open office formats are just zipped folders of XMLs.
Better Zipped XML than whatever monstrosity Adobe files are. PDF/PSD... shudder.
It's not that weird. Most of Office and Open office formats are just zipped folders of XMLs.
Better Zipped XML than whatever monstrosity Adobe files are. PDF/PSD... shudder.
Yep, even music software like Ableton Live is using zipped XML for the project files (although the much bigger audio files are stored independently in sub-folders). There were even efforts to use the XML format to manage Ableton project files with git in order to have a nicer change history (https://github.com/clintburgos/ableton-git).
> with git
I suddenly imagine a zip format with built-in git. Does this already exist?
Basically a file-format that has built-in history, rollback, logs etc. Enabling all these "zipped XML" formats to get this feature "for free".
Could be as simple as adding the .git to the zip and ensuring the software that writes the content to the zip also runs the correct git operations.
But could also be a simplified subset and adding git-ability to the (de)compress libs and bins, which can operate on the compressed .git. Simplified, because it won't need networking/remotes probably not even branches.
> I suddenly imagine a zip format with built-in git. Does this already exist?
OSTree, SQLite (single file DB), OCIRepository, git bundle. But it depends if you rather need code diffs or just versioning of large binary blobs (an image editor needs the latter).
Involuntary reflex reply: ship an SQLite database as your data file?
Quick edit: hmm, I'm already ~1 hour late, the relevant thread starts at https://news.ycombinator.com/item?id=49327457
I mean, zipping files in an archive and presenting them as a file is an ancient tradition in video games. For example Warcraft 3 used the MoPaQ archive to store data in .w3x file.
And Starcraft 2 data is just bunch of XML files.
Except MoPaQ weren't zips IIRC, they had their own clever format here - at least the OG StarCraft / SCBW MoPaQs were, playing with that is what I learned binary data handling on :). The idea of zipping data files applies, of course (and many a game used a literal ZIP with custom extension).
But there's one material difference between StarCraft/Warcraft and Gimp: in Blizzard games, those were "zips" of heavy data files, notably read only data blobs. The game would read them, unpack in memory, and serve appropriately. Most of that data was key-value, text resources, or flat assets - images, sfx. With Gimp, we're talking highly structured data that's continuously being mutated. Very much not the best representation for that, even if you're just persisting it. They're only getting away with this because of SSDs - on spinning rust, you'd feel this.
(Also worth noting that, at least in StarCraft/SCBW, most of the files inside were custom, well-optimized binary formats. This predated the XML insanity of encoding data with 90%+ markup overhead.)
> Except MoPaQ weren't zips
I meant zipping colloquially as in compressing an archive format. But you seem to get the gist of it ;)
> in Blizzard games, those were "zips" of heavy data files, notably read only data blobs. The game would read them, unpack in memory, and serve appropriately.
Not just game files but also the map format for Warcraft 3 was a glorified MPQ (source: https://867380699.github.io/blog/2019/05/09/W3X_Files_Format).
So whenever you edited a WC3 map, you were zipping the current map into an archive. Much like the GIMP example. Of course, WC3 didn't use as many XML files, though SC2 changed that.
Cool, I didn’t know that! But makes a lot of sense.
From https://github.com/zepouet/Xee-xCode-4.5/blob/master/XeePhot...: