I have received some comments on the MAR component patch. Most of it regarding a Interface change, which I am not prepared to do at the moment. There is also a bzip2 issue that still needs to be addressed.
So while wondering how to get that issue resolved, I decided to create a small (a little on the ugly side) XUL app that will generate a complete MAR file that is compatible (I believe that to be true right now, unless I overlooked something) with the Mozilla update system. That is, files are bzip2’d before being put inside the archive.
I haven’t done extensive testing yet. Though, its simple enough that it probably won’t break on you.
There are known issues with it right now that will be fixed with time :
- Its not localized yet, as I hardcoded all the messages.
- It’s one xul file with js in it, so the project still needs to be structured properly.
- One thing you may have to change is the location of the bzip2 utility. Until the bzip2 issue is resolved, the xulapp calls an outside process to handle the compression. The default is /bin/bzip2. If your system has it in a different location, you will need set the appropriate setting in defaults/preferences/prefs.js (there are only two setting at the moment).
- I don’t know how to properly use threads, from JS. I can’t create JS threads, and settimeout() won’t work for what I need to do.
Until that is resolved, the xul window will appear to freeze until the MAR file has been created. This is normal.
- Needs some documentation. But at this point, you can probably figure it out.
- The MAR file should be created in a temporary environment. After you copied the mar file, feel free to delete the remaining files. You can’t specify where to save yet
- It will recurse and copy all files from the root directory and above. There is no way to select certain files, yet.
- You cannot extract MAR files yet.
If your feeling brave or just interested. You can grab a linux build
MAR_generator.tar.bz2 – version 0.1
Windows and MAC builds too someday. Hopefully soon! *hint hint, nudge nudge*
Just because I haven’t blogged in a while, doesn’t mean nothing has been going on. Hopefully, blogging isn’t any indication of how much work your doing (in fact, the people that tend to get the most done tend to blog the least!).
Personally, I’ve been keeping busy. I set up a Picasa photo album on Google (only 1 gig of space?) and put up a bunch of photos of all the interesting things I have done.
Professionally (yay), I’ve been working on creating a MAR component as a first step towards hopefully making it easier for xulapp developers to easily update their xulapps. It won’t get into the tree (as it probably shouldn’t), but there are several xul applications out there that don’t have the ability to update to the next version without completely reinstalling the application.
Of course, my work doesn’t solve the problem completely. There is still the question of developers uploading MARs and the infrastructure in place for users to get them (aus3 anyone?).
One step at a time.
With such redundancy, it wasn’t even worth the effort, other than saving a call back to the server. Coming into Mozilla, I never understood the attraction to the language. It’s too simple, ugly, confusing, and just.. well, going back to the punch card. It seemed obsolete, and I wondered how far this joke of improving the language was going to last.
You know who you are.
Next you’ll be asking me to download Air to view your text-only document.