Search Results: "ag"

10 October 2009

Wouter Verhelst: Fuck you, Sony.

I had wanted to buy a PS3 ever since I learned about this interesting processor that is called the Cell. Not that I'm very much into console gaming or any such thing; I'd have settled for any kind of affordable Cell hardware, really, but that basically is 'the PS3' these days. What I had missed, however, was the fact that recent PS3 machines don't support running Linux anymore. Apparently this was all over the interwebs, but unfortunately I didn't see that. That's 300 I won't see again, for a useless (to me) piece of hardware. Stupid morons.

Andrea Veri: Bits from September / October

Debian maintainer: Some days ago I had the great announcement that my Debian Maintainer s application was accepted and thanks to Jonathan McDowell my key is finally into the debian-maintainers keyring. (which is now part of the debian-keyring itself thanks to the ftp-masters / keyring maintainer work that made the changes on both DAK and keyring) I applied on the 22th of August, and thanks to Reinhard s advocation, everything went on the right side. Many thanks to all the people who made this possible. Pkg-mozext: Around 3 weeks ago I started being involved with the pkg-mozext team working on the new policy and to mozilla-devscripts transition for all iceweasel / icedove extensions. The work is going great so far and we managed to update several extensions that are now part of the team itself. For a fast look at our package list, feel free to browse pkg-mozext s QA page. A lot of work needs to be done, so if anyone wanna jump in, I would suggest to read our guidelines / policy into the team s Wiki Page. Pkg-gnome: GNOME 2.28 is now released, and the pkg-gnome team is now working hard to provide all the needed updates into unstable and experimental. Everything is going great and we are cleaning up everything listed on our schedule. Ephipany is under transition (gecko > webkit) so there are still some open issues / bugs, but now it looks fine so far and it can be used without any particular problem.

Mike Hommey: Iceweasel 3.5.3 in unstable, and fixing RC bugs as a side-effect

I finally started the xulrunner 1.9.1 transition in unstable, and uploaded Iceweasel 3.5.3 there. One of the nice additions to the latest xulrunner (which has actually been in experimental for a couple weeks) is a dh_xulrunner script that adds the proper xulrunner package to shlibs:Depends, which means we are getting nearer to being able to handle xulrunner transitions with binNMUs only. We are still far from it, but it is a step closer. At least, transitions should get a bit easier. The way it works is very hackish, but it apparently works well enough for the packages that currently depend on xulrunner-dev. I also added a xulrunner dh sequence, for the dh users. Anyways, as a side effect of the starting transition, I ended up fixing 4 RC bugs on a single package: Another package with 3 RC bugs is impacted by this transition, but it looks like a good candidate for removal. That s 7 RC bugs adressed by this transition, while not directly related to xulrunner.

Dirk Eddelbuettel: R for system administration and scripting

On several occassions, R had suggested itself as a language for <it>systems scripting</it>. By this I mean random little adminstrative task such as (re-)moving or maybe renaming files or directories and the like. One of such cases just happened a few minutes ago. The aforementioned Garmin Forerunner 405 can cooperate quite nicely with Linux using the gant reader for the ant wireless communication protocol between the usb hardware dongle and the Garmin 405. (Sources for gant are both this file and this git archive.) I had meant to blog about this tool and the resulting files one of these days anyway, but today I just want to mention that the default filenames created by the program were somewhat horrid such as 20.09.2009 101112.TCX to denote the 20th of September of this year at 10:11h and 12 seconds. As we all know, filenames with spaces are bad for the environment as well as plain annoying. So I had made the simple change in the C sources to switch to a saner format such as 20090920-101112.TCX (and I see that the git archive now contains a similar fix). But that still left me with some 80+ files with the dreaded names. There are of course many ways to skin this cat and to rename the files in bulk. However, I found the following four lines to be fairly succinct
#!/usr/bin/r
files <- dir(".", pattern=".*\\.TCX$")
res <- lapply(files, function(f)  
    pt <- strptime(f, "%d.%m.%Y %H%M%S.TCX")  # parsed time
    ft <- strftime(pt, "%Y%m%d-%H%M%S.TCX")   # formatted time
    file.rename(f, ft)
 )
as they show, among other things, So about five lines and two minutes later, some eighty-ish files were renamed and sanity was restored. Hm, and I took me five times as long to blog this. Lastly, I do not mean to imply that Python or Perl or Ruby or (insert favourite tool here) cannot do it equally well. I simply meant to say that programmatically creating new filenames is definitely easier in R than it would have been in shell. And as an added bonus, we even get fully parsed time objects that I could have tested for. But then tests and documentation never get written on a Saturday.

Bastian Venthur: python-debianbts 1.0 uploaded to unstable

Today I was working all day on python-debianbts 1.0 and uploaded it to unstable a few minutes ago. This version breaks backwards compatibility with previous versions. I removed lots of unneeded old cruft like the HTMLStripper class needed ages ago when I was still using HTML instead of debbugs SOAP interface. A new method get_usertag(email, *tags) was introduced. It returns a dict containing usertag-buglist mappings. If tags are given the dict is limited to matching tags, otherwise all available tags of the given user are returned:
In [1]: import debianbts as bts
In [2]: bts.get_usertag( debian-python@lists.debian.org )
Out[2]:
 dist-packages : [547838, 547832, ..., 547858],
  dpmt-todo : [332913],
  policy : [373301, 373302, ..., 377089],
  python-oldnum : [478467, 478442, ..., 478441],
  python2.1 : [351108, 351110, ..., 351131],
  python2.2 : [351108, 351109, ..., 351161],
  python2.6 : [547838, 547832, ... 547858] 
In [3]: bts.get_usertag( debian-python@lists.debian.org ,  python2.1 ,  python2.2 )
Out[3]:
 python2.1 : [351108, 351110, ..., 351131],
  python2.2 : [351108, 351109, ..., 351161] 
get_bug_log(nr) now returns a list of dicts with the keys: header (string), body (string), msg_num (int) and attachments (list). Before 1.0 it returned a list of Buglog objects. The Bugreport class now supports every information provided by the SOAP interface. I tried to stay as close as possible to the data SOAP provides, so I renamed existing attributes (like Bugreport.nr which is not supported by SOAP but is now Bugreport.bug_num) and also added the quirky ones like: id and bug_nr, found and found_versions, keywords and tags, fixed and fixed_date which always seem to provide the same data. Instead of the Bugreport.value() method which provided a number representing the openness (in terms of: open, closed and archived) and urgency (like: grave, important, ) to make bugreports sortable by their status, the Bugreport class now has a __cmp__ method which makes bugreports comparable. The more open and urgent a bug is, the greater it is. Openness always beats urgency (eg: an open whishlist bug is greater than a closed grave one). While pre 1.0 versions of python-debianbts more or less served the needs of reportbug-ng, it now tries to stay as close as possible to the data provided by SOAP. As a result many parts of reportbug-ng had to be fixed for the new version. I hope this makes python-debianbts more attractive for other projects dealing with Debian s bug tracker. As always: python-debianbts is on github and forks, patches or other kinds of collaboration are very welcome. For the curious here a litte quickstart. it shows how to get all important bugs from reportbug-ng and prints out the bugnumber and summary:
# Get all important bugs of reportbug-ng (returns a list of integers)
bugnrlist = bts.get_bugs("package", "reportbug-ng", "severity", "important")
bugnrlist
[548871, 439203, 542759]
# Get the actual bugreports (returns a list of Bugreport-objects)
bugs = bts.get_status(bugnrlist)
for bug in bugs: print bug.bug_num, bug.subject
    .:
542759 [reportbug-ng] Erroneously reports nothing or repeats previous package s report
439203 Doesn t give any explanations of the severities and what they mean
548871 reportbug-ng: does not check for newer versions before reporting a bug

David Pashley: Blog Copyright

To make things explicitly clear, my blog is copyrighted and licensed as "All rights reserved". It even says that at the footer of every page. That means you may not redistribute any content without my permission. Yes, this means you, Ross Beazley. I may allow aggregation sites to redistribute my content, but the only sites where I have given explicit permission are Planet Debian and Planet BNM. I am unlikely to be upset if your aggregation site links back to the original entry and does not carry advertising, and will probably give you permission. If both these conditions are not met, you do not have permission and will not be granted permission.
Read Comments (7)

David Paleino: Bash-completion 1.1 released

Here we go, another release has been cooked for your enjoyment: bash-completion 1.1 is here! This release's development cycle has seen the release of bash4: this introduced a number of bugs, which have been hopefully fixed. Blame us if you find any other Smile Many completions were split out of bash_completion: this prepares the road to dynamic loading of needed completions (in a future major release), resulting in a smaller and faster completion! Furthermore, like each release, many new completions have been added, many old ones were improved, and some bugs have been fixed (more than 20). For more info, look at the changelog file. Still there? Go download bash-completion-1.1! For any bug you might find, please contact us at our mailing list, or directly file it at the Alioth tracker. For the Debian users out there: package coming soon! Happy installation!

Stefano Zacchiroli: RC bugs of the week - week 6

RCBW - week #6 RC bugs squashed this week by yours truly: This week I've cheated for at least two reasons:
  1. the first 4 entries in the list above are bugs of "mine", since within the Debian OCaml Maintainers team we migrated to a new package toolchain called dh_ocaml (with a lot of advantages I've anticipated before my summer break). The migration to that triggered (thanks, Lucas! :-) ) more than 30 FTBFSs which had to be dealt with. So, even if not cheating, it is at least breaking the NMU tradition of RCBW, but they were still RC bugs looking for a fix! All in all, I'm impressed by the fact that in about a week we dealt with most of them.
  2. the lxml fix above is severity "important" and as such, not RC. I attacked that because I intended to help out with the Python 2.6 transition which is still, at the time of writing, 41 bugs away from hitting unstable. I confess I did not find the task particularly fun (which is a requirement for me when I work on packages which are not mine) yet, we'll see next week ...
The feeling of the week I've to share is that I'm more and more impressed to not have received any complaint about my NMU activity, and I'm approaching the 50 NMUs. Actually I've received several "thank you" replies (you rock guys and you know who you are). On one hand this is probably a good indication that I haven't (yet) done any serious mistake; I do love peer-review! On the other hand, and more importantly, this is dispelling inside me the folklore / cultural block we have in Debian that "NMU is bad", while NMUing should become a way to help each other routinely. Really.

Jaldhar Vyas: Barack Obama is a Keynesian

pointless award I haven't written about politics since the election for several reasons. First and foremost, Obama won fair and square. While I might wish the other guy had won, I can't whine and pout or threaten to move to Canada like some people. The vox populi chose and that choice has to be respected. Secondly, one of the worst aspects of the current American political scene is the paranoid obsession with personalities in which the president is not just an implementor of policies good or bad, but personally responsible for the entire state of the cosmos. It started with Nixon, started getting alarming with Clinton and reached batshit levels of insanity with George W. Bush. But just because the left does it it, doesn't mean we have to follow suit. Although I figured Obamas policies would end up a trainwreck, I wanted to see what he actually did before calling him on it. The Nobel comittee isn't hoping and changing with me. In a decison that is bizarre even by the lax standards of a prize that long since jumped the shark, the President is to receive the Nobel Peace prize for...not being George Bush? It's difficult to see what substantive reasons they could have for their choice. But apparently one of these days he is going to make extraordinary efforts to strengthen international diplomacy and cooperation between peoples...democracy and human rights are to be strengthened. Well let's see now: Perhaps I am being a little unfair in not taking into consideration all the great things the president is going to do real soon now. It's just that I'm worried that this might be an attempt to sway him in the task of winning the war in Afghanistan (and more likely than not carrying it into Iran and Pakistan.) I take solace in the knowledge that heretofore Obama has shown a refreshing inclination to throw people under the bus when they are no longer convenient. If he can do that to the guy who says he wrote his book than some silly Norwegians won't be a problem.

9 October 2009

Martin Meredith: Call for stickers

Random plea for free stuff. If anyone out there has any geeky stickers (or anything a bit random for a sticker) lying around, please send them to me! I d rather not put my address on the intarwebs, so please feel free to email me on martin AT sourceguru DOT net if you have something to send me, and I will happily send you out a Stamped Addressed Envelope. The stickers will be put to good use decorating my laptop ;) Edit:- I ve just realised that sending a SASE to another country really doesn t work particularly well, different countries use different stamps after all!!!!
I m trying to think up a solution, but please let it be known that I am in the U.K., so if you re outside and want to send me stickers, you may have to help me come up with a solution for getting round the whole stamp thing!

Michal &#268;iha&#345;: New Wammu and Gammu website

I just put online new Wammu and Gammu website at http://wammu.eu/. The reason for this change is that I want all relevant information about Gammu and related programs to be available in one place. You can find there information about Gammu, SMSD and python-gammu as well including some information and documentation which used to be spread in wiki and various other documents. Also all Gammu and Wammu related announcements will be published only on that website and will no longer pollute my blog (and all planets where my blog is being syndicated). If you followed RSS feed, you should update your reader to http://wammu.eu/news/rss/. The new website also includes updated Gammu Phone Database, which will look almost same to users, but has been completely rewritten underneath, what will allow some extensions in future and allows easier management of entries for me. What currently lacks behind old website is Czech translation. The reason is in simple fact that new website contains much more texts and I did not yet have time to translate it. If you want to help, just go to l10n.cihar.com, or just follow translators instructions. This time it will be also possible to add other translations, so if you want to translate website to other language, you are welcome!

Martin Meredith: Most Awesome Warranty Ever!

If this product should fail in your lifetime, we will replace it at no charge. If the proeducts is damaged by aggressive music listeners sliding a rail, sliding down the emergency ramp of your aircraft, slammed in your locker, slammed in your car door, run over by a car, running into a wall, getting run out of town, mountain biking, road biking, sky diving, beating your boyfriend unmercifully, getting beat down by the man, blown up in an accidental experimentation with flammable substances or damaged in any other every day experience, it means you are living your life the way we want our product used! In these, or any other damaging events, we will replace the product for a 50% discount from retail.
Skullcandy rock! I m loving my new headphones

Eddy Petri&#537;or: Converting flac to mp3 - Soundconverter

Why would I want that? Not because mp3 is in any way superior, is just my phone doesn't support playing FLAC and its audio capabilities are no match for flac.

If you want to convert FLAC to mp3, say to listen to your music on your phone or mp3 player, and you use GNU/Linux I recommend soundconverter.

This is already packaged in Debian and available in etch, lenny, squeeze and sid. It is probably available on Ubuntu and all other major distros out there, so, enjoy.


(This is also a reminder for me. I used soundconverter before, but I was unable to remember which was the application.)

Brett Parker: Firefox Paper Size

It appears that no matter what the system papersize is set to, and no matter what cups says is the default paper size, firefox, in its infinite wisdom locks it to being letter - this would probably be fine if I was in the US, but I'm not, and I want it to be A4... So, the stages to go through to get it to do the right thing appear to be: This seems like something that should be much easier set, apparently using Page Setup only affects the current tab/window you are in and doesn't change the default, which is just odd.

8 October 2009

Rapha&#235;l Hertzog: 3-way merge of Debian changelog files

I ve been considering for some time now to create a merge tool specifically suited for debian/changelog files. My goal was to let Git use it automatically thanks to gitattributes. I ve just gone ahead, so let me introduce you git-merge-dch. Grab it with git clone git://git.debian.org/~hertzog/git-merge-dch.git, you can build a package if you wish. Beware, you need to have a dpkg-dev 1.15.5 that is not yet published (so you need to build dpkg from its git repository, git clone git://git.debian.org/dpkg/dpkg.git) as I rely on features that I introduced recently you will also need the libalgorithm-merge-perl package. Using it in a git repository requires two changes: Now you can safely maintain two branches of a package with changelog files evolving separately and merge one into the other without creating undue conflicts. Suppose you created an experimental branch for version 2.28 (you use a version 2.28-1~exp1) when 2.26.2 was current stable in the master branch. In the mean time, 2.26.3 got out and was packaged in master. Next time you merge stable into experimental, the changelog entries for 2.28 and 2.26.3 won t collide despite being at the same place in the changelog file compared to the common ancestor. Let s continue with this example, 2.28 is out. Instead of adding a new changelog entry with New upstream release without further changes, you keep the current changelog entry and simply change the version into 2.28-1. While preparing this you discover a branch with fixes that was based on 2.28-1~exp1, if you merge it it will reintroduce a 2.28-1~exp1 entry that you don t want. Fortunately you can use the --merge-prereleases (-m) option of git-merge-dch so that it strip the prerelease part of the version string and considers 2.28-1~exp1 and 2.28-1 to be the same entry really. The only limitation is that this merge tool will remove any lines which are not parsed by Dpkg::Changelog (and which in theory are not supposed to be there). Feel free to test, share your comments, report bugs and send patches! Partagez cet article / Share This

Stefano Zacchiroli: cowbuilder gotcha

don't set DEBEMAIL in /etc/pbuilderrc That's pretty much it. The reason is that, if you do set DEBEMAIL pbuilder/cowbuilder configuration option (most likely, to the same value of your $DEBEMAIL envvar) you will end up generating .changes file containing fields like:
    Maintainer: Stefano Zacchiroli <zack@debian.org>
    Changed-By: Stefano Zacchiroli <zack@debian.org>

even when you're not the maintainer, e.g. when the maintainer is a team address or when you are doing an NMU (which I've been doing quite a lot recently). I discovered this thanks to Ana about a month ago and it quite shocked me, since I've been using the same pbuilder (and then cowbuilder) configuration for quite a while (years ...) without realizing that. The complicity of a missing lintian check has surely helped (wishlist bug filed) as well as a weird/buggy behavior on the *builder side (there are some bugs on that line, I just haven't taken the time yet to understand what should be the correct behavior). Bottom line: just check whether you are screwing up *.changes file due to overzealous attitude in *builder configuration :-)

Barry Hawkins: More Expensive and Complicated Equals Better: Carseats and Software

So I finally got around to checking out the TED site; I ve quickly become a fan. One of the first talks I watched was Steven Levitt s child carseats talk. Both the talk and the feedback comments on the TED site reminded me of things I see in software development. Here s the video if you haven t seen it.
<object height="326" width="334"><param name="movie" value="http://video.ted.com/assets/player/swf/EmbedPlayer.swf"><param name="allowFullScreen" value="true"><param name="wmode" value="transparent"><param name="bgColor" value="#ffffff"><param name="flashvars" value="vu=http://video.ted.com/talks/dynamic/StevenLevitt_2005G-medium.flv&amp;su=http://images.ted.com/images/ted/tedindex/embed-posters/StevenLevitt-2005G.embed_thumbnail.jpg&amp;vw=320&amp;vh=240&amp;ap=0&amp;ti=30&amp;introDuration=16500&amp;adDuration=4000&amp;postAdDuration=2000&amp;adKeys=talk=steven_levitt_on_child_carseats;year=2005;theme=unconventional_explanations;theme=presentation_innovation;theme=how_the_mind_works;theme=not_business_as_usual;event=TEDGlobal+2005;&amp;preAdTag=tconf.ted/embed;tile=1;sz=512x288;"><embed allowfullscreen="true" bgcolor="#ffffff" flashvars="vu=http://video.ted.com/talks/dynamic/StevenLevitt_2005G-medium.flv&amp;su=http://images.ted.com/images/ted/tedindex/embed-posters/StevenLevitt-2005G.embed_thumbnail.jpg&amp;vw=320&amp;vh=240&amp;ap=0&amp;ti=30&amp;introDuration=16500&amp;adDuration=4000&amp;postAdDuration=2000&amp;adKeys=talk=steven_levitt_on_child_carseats;year=2005;theme=unconventional_explanations;theme=presentation_innovation;theme=how_the_mind_works;theme=not_business_as_usual;event=TEDGlobal+2005;" height="326" pluginspace="http://www.macromedia.com/go/getflashplayer" src="http://video.ted.com/assets/player/swf/EmbedPlayer.swf" type="application/x-shockwave-flash" width="334" wmode="transparent"></embed></object>
Steven Levitt shows in his talk how 30 years of data on car crash fatalities imply that carseats do not outperform regular seatbelts for children ages 2 and up. Anyone who has a child or grandchildren will probably bristle at hearing that; as the father of a pre-schooler, it certainly gave me pause. We spent no small amount of time and decent chunk of money in selecting carseats for our child, thinking we had done our best to ensure our child s safety. For that matter, it would be illegal for us not to have done so. To see a decent-sized data sample suggesting my child would be better off in a seatbelt at her age is rather unsettling. By the end of the talk, I took away these observations: So, software professionals, does any of that sound familiar? It reminds me of numerous initiatives over the years that have led us inexorably to the software productivity morass we have slogged through for years now. I suppose the most heinous case study in my own experience would be J2EE and the insistence that it was the solution that any reasonable business application would choose for a platform. (Before you .Net folks jump on that one, DCOM and later the .Net enterprise stack was much the same.) And who hasn t read a benchmark or white paper with seemingly incontrovertible data depicted in highly-polished graphics insisting that Product Y is the one solution to address them all? I noticed that there were comments below the video on its page at the TED site, largely because the negative verbiage of the topmost comment jumped out at me. I took the time to read through them all (there were 36 at the time of this writing), and to my amusement, I saw parallels between them and how people react to questioning and examining our existing practices and means of developing software. See if any of these strike a chord: In recent years I ve been greatly encouraged by the willingness of companies to question whether or not the heavyweight frameworks and technology stacks are what they should be using. Helping companies slough off high-ceremony processes in favor of right-sized process that focuses on delivering the right software in a timely manner has been some of the more rewarding work I ve done the past several years. I think we have an encouraging number of people in the industry who are challenging the more expensive and complicated always equals better mantra. For the brave individuals willing to put these questions to the community at large, I hope you find some comfort in knowing that the resistance and rejection you will encounter is a thing to be expected; you are not alone in that respect. Here s hoping we continue to be open to self-examination, no matter what emotional responses it might provoke or what fear of the future it may stir up within us.

Martin F. Krafft: Commencing work on the second edition of my book

Today I branched the (LaTeX) source of my Debian book in preparation of the second edition, targetted for the forthcoming Debian 6.0 squeeze . I am very excited to come back to this project after deprioritising it in favour of my research for too long. Thanks to my publishers Open Source Press and No Starch Press for their patience. If you want to be the first to receive announcements about the book, such as release dates, previews, or other information, please sign up to the announcement mailing list. The second edition has two goals: I want to re-establish the book as the standard Debian reference, but also to give my existing readers a good reason to buy the book again. While we re on the topic of buying: yes, the book is pay-ware, and yes, in some ways that goes against the spirit of open-source, and Debian in particular. However, this is a choice I made. If this book didn t have a commercial basis, then I could not put as much time into it, and I would not be able to profit from the outstanding help from the folks at Open Source Press and No Starch Press it is thanks to their advice and experience that the book turned out to be as it is. The book will be available as PDF from the start, so if you care as much about the environment as I do, you ll prefer to get that over the Dead Tree Version. And if you re as haptic as I am, then you still have the option to buy the book so you can hold something real in your hands. I am looking forward to working on this project, to working intensely with the Debian community throughout, and to your input.

Joey Hess: ikiwiki dependency types

Like make(1), ikiwiki knows about dependencies between the files that it is building, and will rebuild a file if its dependencies change. I've always known that it was possible to greatly reduce the amount of work ikiwiki does, if it gets smarter handling of different types of dependencies. It would be as if make knew that changes to comments inside header files did not change the resulting binary, and avoided rebuilding it for such a change -- but did rebuild the doxygen documentation. Except that, in ikiwiki, this can be done sanely, since it figures out the dependencies by examing the wiki's files, not by using a Makefile. Also, there were some nasty bugs with certian complex dependencies not being handled right. Fixing one of them, the transitive dependency problem, would require ikiwiki doing significantly more work. So fixing all this has been on my todo list for a while. Though when I mentioned "transitive dependencies" at the ikiwiki BOF @ DebConf, eyes glazed over. :) And I expect I've lost most of my readers already here too.. Which is a pity, because I've just gotten to the fun stuff. So, a few (how many?!) days ago I started my current insane hackfest, and began adding dependency types into ikiwiki. The first special type was a presence dependency -- a dependency that only cares if a page is created, or deleted, but does not care about changes to the page. Next type was a links dependency -- a dependency that only cares if the page changes what pages it links to. That was great, except it often didn't work. For features like gathering "posts/*" together into a blog, or displaying a tag cloud of "tags/*", ikiwiki uses a PageSpec. This is a small, domain specific language, that can specify a set of pages with lots of control. For example, "(index or backlink(index)) and created_after(oldpage)". The problem is that when using a PageSpec like the one above in a presence dependency, it doesn't only matter if pages are added/removed. Certian changes to "oldpage" or "index" can also change what it matches. So now, I had this PageSpec DSL, that I needed to somehow analyise to find these influences. While thankfully not turing-complete, parsing it to extract the influences would still be annoying. Except: Operator overloading to the rescue! The solution was this perl:
package IkiWiki::FailReason;
use overload (
        '""'    => sub   $_[0][0]  ,
        '0+'    => sub   0  ,
        '!'     => sub   bless $_[0], 'IkiWiki::SuccessReason' ,
        '&'     => sub   $_[0]->merge_influences($_[1]); $_[0]  ,
        ' '     => sub   $_[1]->merge_influences($_[0]); $_[1]  ,
        fallback => 1,
);
package IkiWiki::SuccessReason;
use overload (
        '""'    => sub   $_[0][0]  ,
        '0+'    => sub   1  ,
        '!'     => sub   bless $_[0], 'IkiWiki::FailReason' ,
        '&'     => sub   $_[1]->merge_influences($_[0]); $_[1]  ,
        ' '     => sub   $_[0]->merge_influences($_[1]); $_[0]  ,
        fallback => 1,
);
Ikiwiki already dealt with pagespecs by translating them to perl (which is then compiled (yes, perl can), and happily memoized). A pagespec is translated to something like this:
(match_glob("index")   match_backlink("index")) & match_created_after("oldpage")
The match_* functions return IkiWiki::SuccessReason or IkiWiki::FailReason objects. These objects are special in a lot of ways; they act like boolean values most of the time, but if viewed as a string, you get a user-understandable message saying why the pagespec didn't match. And when ANDed or ORed together, they build up a list of influences, that can be accessed at the end to get all the influences for the whole pagespec. (Why am I using what's supposed to be bitwise operations & and , rather than "and" and "or"? Because perl doesn't seem to consider the latter to be operators. Odd.) Anyway, this stuff should be available in an ikiwiki release just as soon as I've finished making it smoking fast.

7 October 2009

Adnan Hodzic: DebConf11 bid in Banja Luka?

Yesterday was a glorious day for DebConf11 bid in Bosnia and Herzegovina. I had a scheduled meeting with Banja Luka s mayor Dragoljub Davidovic. We met in his cabinet, where I presented him with the paper DebConf11 in Bosnia and Herzegovina in which I tried to explain what it all means. From what Debian is, over what DebConf is, to why is DebConf important. The thing I was most worried about was how am I going to explain all this in simple non-tech words Smile Either way, I was in middle of explaining what Debian is when mayor interrupted me I understand, I m electrical engineer myself you have no idea what relief came from these words! Grin Explaining what DebConf is and what kind of profiles attend one such event went smoothly as well, where mayor made some replicas on my story from the projects he worked on and so on. After my last case he also explained me how it s good that we meet, since Banja Luka was known as electronic city in ex-Yugoslavia.


Mayor and I
And this is where things start going just ballistic! He says something along the line this is a great idea and that we have his full support, I think you should talk to the prime minister (Milorad Dodik) about this as well! Shock I find my way to the government building, wait for brief period of time and I get called inside of the prime ministers cabinet. I tell him somewhat different story, in terms of more details, how we are competing with M nchen for this bid, and how I m actually planning if we win the bid, and if the bid is successful we d most likely change the whole city s infrastructure to Debian. He picks up the phone and calls for someone, person comes in and I m introduced to IT Center General Manager (Krsto Grujic). He tells me that they have few RedHat servers while he leads the way to his office where I m introduced to director of Agency for IT (Srdjan Rajcevic) where we even have this informal talk where Srdjan tells me he used GNU/Linux user himself and that he still manages two OpenBSD servers. We talk about various topics, in the end I tell them what we need for the conference, they write it all down and we exchange contact details, since I was called back up by the prime minister. Prime minister, asks me what I need from him to realize this project and I tell him that I d need everything I gave IT guys below, and binding papers that we d have full government and city support by the end of the month, and that I ll consult with people from Debian in case we need anything else. No problem were his words Grin
Prime minister and I
I walk out, really asking myself, what just happened, was that a Disney movie or what? Cool I d really like to use this opportunity to invite all Debian members to come and help us realize this bid. Help us put Bosnia and Herzegovina on map of the open source world! Stay tuned Wink

Next.

Previous.