Nautilus with libkibi

In this Ubuntu cycle, I work on getting the units policy implemented. For this I wrote a library called libkibi. Here are some screen shots how nautilus looks like with libkibi. Some changes are highlighted in red.

The file properties will show the file size in base10 and base2:

PS: I failed to launch nautilus in English. Therefore the screen shots are in German.

PS²: You can grab the modified nautilus package for Ubuntu 10.10 (maverick) from my experimental PPA (at your own risk!).

libkibi ready for testing

Yes, the library is finally called libkibi. The second poll ended with a tie between libbyteprefix (48 votes) and libkibi (45 votes). Then I decided to call the library libkibi.

libkibi is hosted on Launchpad. A working version can be pulled from lp:libkibi with bzr. Please test the library, reports bugs, and ask questions.

Why you should use libkibi instead of g_format_size_for_display (from GLib):

  • the users can configure their preferred prefix
  • rounds correctly (converting an integer to double, do some math, and then round again leads to rounding errors)
  • complies to Ubuntu’s Units Policy (except “historic” is selected)
  • is faster (between 15% and 35% depending on the processor)

Poll: libkibi VS libbyteprefix (or: How to call the library? 2)

Dear lazy web,

thanks for voting the best name for the library that helps implementing the Units Policy of Ubuntu. The winner with the most votes has been libkibi. There was one suggestion that got my attention: libbyteprefix. The suggestion came too late to have a chance. Therefore I ask you again to vote for the library name, but this time only these two names are open for voting: libkibi and libbyteprefix. libkibi is short and sounds good. On the other hand, libbyteprefix describes exactly what the library is supposed to do.

I was asked to use a free (as in freedom) poll-service. So please go to the Selectricity unitspolity vote and select your favorite. Thanks.

Poll: How to call the library?

Dear lazy web,

I am writing a library that implements the Units Policy of Ubuntu. This library can be used to format sizes (of files, disks, memory, etc.) for displaying them and the other way around. For example, the size 12345 bytes can be formatted to 12.3 kB, 12.1 KiB, or 12.1 KB depending on the configuration. An other function will give you the possibility to convert 12.3 kB, 12.1 KiB, or 12.1 KB back to 12345 bytes. The preferred binary unit can be configured by an text file (per system and per user) and by an environment variable. The library is written in C and doesn’t have any dependency. Therefore it can be used by any program on any desktop environment. Binding to other languages like C++, Python, Java are planned.

Before creating a project for this library, I need a name for the library. The current prototype is called libdisplayunits, but this name reflect only the half of the project. It does not indicate that the library can be used for inputting sizes. What do you think? What is the best name for the library? Please poll and/or comment below.

Daily builds rock, but bzr imports suck

Ubuntu‘s development platform Launchpad recently gained the ability to create daily builds. BzrBuilder is used for creating source tarballs and PPAs are used for building the source tarballs. BzrBuilder uses a recipe that declares how to build a source from different bzr branches. In most cases you have a bzr import from the upstream version control system. Then you nest a bzr branch that contains the packaging information. This works great for

but the bzr import for these projects fail:

  • Audacious: Import fails with infinite recursion (LP: #519709)
  • Eclipse: Launchpad disallows valid CVS module of ‘.’ from being imported (LP: #594294)
  • VLC: Code Imports does not support submodules (LP: #402814)
  • XMMS2: Code Imports does not support submodules (LP: #402814)

How many packages have you sponsored?

How many packages have you sponsored in the maverick release cycle? Check your mailbox for mails that have a header starting with [ubuntu/maverick]. Then subtract the number of own uploads (you can find them on the Uploaded packages site on your Launchpad account).

In my case, I have uploaded 45 own packages and sponsored 191 packages. That’s approximately four times more sponsored packages than own ones.

Is your ratio smaller than mine? Then go to the sponsoring overview and grab one bug and work on it. The code review process is described on the Ubuntu wiki.