One package for every OS

View the Project on GitHub dbenamy/0install


0install is the last package manager you'll ever need:

0install can install programs from built in catalogs, or from any site.

$ 0install add rox-edit
$ rox-edit
$ 0install add http://0install.de/feeds/Audacity.xml # no central repo needed
$ audacity

TODO This assumes support for short names is ported from the windows version to everywhere.

There's also a GUI.

TODO screenshots from http://0install.net/user-guide-shortcuts.html.

TODO I think that the command line and gui worlds should be unified if they're not. "0install add", AddApp, and the gui manager should all set up gui shortcuts and add the program to $PATH by default. If not, we have to explain the differences and I bet people will be confused. Hell, I'd be confused :-)

0install puts everything in /var/cache/0install.net/, other than the launch scripts and desktop shortcuts. It won't step on any of your other software or interfere with any other package manager.

It's easy to create your own 0install packages. Let's package SCons, a build system written in python.

$ mkdir 0install-scons && cd 0install-scons
$ 0install add 0publish http://0install.net/2006/interfaces/0publish
$ export EDITOR=nano # if your EDITOR environment variable isn't already set.
$ 0publish SCons.xml # The file name shouldn't have a version number.

TODO We can reduce onboarding friction by making 0publish a subcommand of 0install so they don't have to install something else. I guess the down side is that 0publish gets a little bigger for everyone.

Type "Y" to create the file. It should open in your editor. Fill in the summary, description, homepage, and the main program (in this case, scons.py). The final version should look like:

<?xml version="1.0" ?>
<?xml-stylesheet type='text/xsl' href='http://0install.net/2006/stylesheets/interface.xsl'?>

<interface xmlns="http://zero-install.sourceforge.net/2004/injector/interface">
  <summary>a software construction tool</summary>
SCons is a software construction tool (build tool substitute for Make)
  <group main="scons.py">
    <implementation id="." version="0.1" released='Snapshot'/>

Save to the default file and exit your editor.

$ 0publish Scons.xml \
  --set-version=0.96.92 \
  --stable \ # if this is a stable release (the default is testing)
  --set-released=today \

Decide where you'll put the package. Programs will depend on this so it should be somewhere that won't change. You might put it on your site, like https://example.com/0install/SCons.xml, or you might keep it in revisions control, like:

$ export PACKAGE_URL=https://github.com/scons/scons/master/Scons.xml
$ 0publish Scons.xml --set-interface-uri="$PACKAGE_URL"

$ gpg --gen-key # if you don't have one. You just need name and email address.
$ 0publish SCons.xml --xmlsign

Finally, upload or push SCons.xml and your GPG public key to the same directory.

All done! Now anyone can run it:

$ 0install add my-cool-scons $PACKAGE_URL
$ my-cool-scons --version

If you want to make manual changes to the package, use

0publish Scons.xml --edit

which will validate and re-sign the file when you save.

When you release a new version:

$ 0publish SCons.xml \
  --add-version=1.0 \ # instead of --set-version above
  --stable \ # or not
  --set-released=today \

There's also a gui for creating packages.

$ 0install add 0publish-gui http://0install.net/2007/interfaces/0publish-gui.xml
$ 0publish-gui

TODO replace with screenshots of gui-only workflow.

There's lots more good stuff under the hood.


Packaging Other Kinds of Programs

TODO something that gets built

TODO from a .deb or .rpm

TODO others?

More Info

0install Site