Address management with ConTagged

Whenever you start a new company there seem the be the same infrastructure problems: mail, calendar and address management. I consider mail and calendar almost a “solved problem” now with Zimbra and Google Apps (we’re using the latter at Nektoon and used Zimbra at local.ch). But proper contact handling is still hard. Google Apps strangely enough doesn’t seem to include shared contacts. There is of course Lotus Notes, MS Exchange and again Zimbra. But somehow I was never quite happy with Zimbra’s address management. Additionally - me being a geek - I’d really like LDAP access to my addresses. This allows for all kinds of great integrations. ...

January 22, 2009 · Patrice Neff

Script to copy my home directory

Since a few months I keep configuration parts of my home directory managed with git. This allows me to easily check out my home directory on my servers and have access to the same environment. Today I wrote a script to make that slightly easier. I wrote the following script which is stored as ~/bin/init-host. #!/bin/bash # # Copies my git repository to the given host. cd ~/ echo "You'll be asked for your password on each host." for host in $*; do tar -czf - .git | ssh $host "git --version && \ tar -xvzf - --exclude '._*' && \ git reset --hard HEAD" done It logs into all hosts given as command line parameters. On each it deploys the home directory using the ~/.git repository. A few specialties: ...

January 20, 2009 · Patrice Neff

Install Python 2.6 on Debian Etch

Debian doesn’t yet have any Python 2.6 packages. But creating them on your own is very easy. You can: download my package or build your own and learn something in the process. The download will disappear as soon as I see some real distribution which doesn’t take all my shortcuts. So this are step-by-step instructions for typing in your shell. Download $ curl -O http://www.python.org/ftp/python/2.6.1/Python-2.6.1.tar.bz2 $ mv Python-2.6.1.tar.bz2 python2.6-2.6.1.tar.bz2 $ tar -xvjf python2.6-2.6.1.tar.bz2 $ mv Python-2.6.1 python2.6-2.6.1 $ cd python2.6-2.6.1/ You need to properly name the directories as “packagename-version”. In this case the package name is “python2.6” - not “python” - which is why the version seems to be repeated. ...

January 14, 2009 · Patrice Neff

Proper file overwrites in Python

For Nektoon I’m implementing a storage service in Python. It will work with individual text files that it exposes over a REST API. I struggled a bit with how to correctly handle file overwrites. In the end I came up with this code: import os import portalocker if os.name == 'posix': # Rely on the atomicity of Posix renames. rename = os.rename else: def _rename(src, dst): """Rename the file or directory src to dst. If dst exists and is a file, it will be replaced silently if the user has permission. """ if os.path.exists(src) and os.path.isfile(dst): os.remove(dst) os.rename(src, dst) def write(filename, contents): filename_tmp = filename + '.TMP' with open(filename_tmp, 'a') as lockfile: portalocker.lock(lockfile, portalocker.LOCK_EX) with open(filename_tmp, 'w') as out_file: out_file.write(contents) rename(filename_tmp, filename) There are two important parts here. ...

January 5, 2009 · Patrice Neff

Setting sail again

Today is my last day at local.ch. I have been involved with that company since the beginning of 2005 with the initial prototypes. After my time in Peru I then started as a full-time employee in May 2006. That was a few days after the very first version of local.ch had gone live. So I spent close to four years involved with the project and of that two years and seven months as an employee. ...

December 12, 2008 · Patrice Neff

Google's iPhone back button hack

Google provides an iPhone application for Google search. What I found interesting is how they make sure the back button works consistently. If you’re not familiar with the application, that’s a normal workflow: Enter a search term. Along the way you get search results for partial queries and proposed auto-completed queries. Click any item in the search result. iPhone’s Safari is now launched with the target page. At this point you leave Google’s application. Because of the application model on the iPhone this also means that the Google application gets closed completely. Now for the hack that Google implemented. The back-button works in Safari. It does the following actions: ...

November 27, 2008 · Patrice Neff

Active positive feedback

At local.ch we have a Wall of fame in our wiki. In my personal opinion this is one of the best ideas we’ve ever had when it comes to our team organisation. The reason is that negative feedback gets delivered very quickly and all the time. Strangely enough you have to invest more in making sure positive feedback also gets around. So what happens now is that if somebody helps a colleague or the whole team in a special way, that person gets an entry in the hall of fame. It’s a really encouraging sight to scroll through that list and see how much people are helping each other. And how thankful the recipients are. ...

November 20, 2008 · Patrice Neff

Overcoming Scrum prejudices

Scrum is a software development method. It’s been on my radar for a long time but mostly with a negative air to it. After I finally overcame a lot of my prejudices, I recently started to look into it seriously. And it turns out it makes a lot more sense and it’s a lot easier than I used to think. I blame the gazillions of Scrum consultancies out there for sometimes overcomplicating things. In the end it comes down to these few points: ...

November 18, 2008 · Patrice Neff

1 Million gratis Telefonanrufe

local.ch bietet eine Million gratis Telefonanrufe für Schweizer KMUs. Nachdem die Schweizer Banken nun 68 Milliarden erhalten haben, will local.ch auch den Schweizer KMUs etwas schenken. local.ch zeigt wie’s geht (Disclaimer: Ich arbeite für local.ch ag)

October 28, 2008 · Patrice Neff

SBB verbannt Suprise Magazin

In der NZZ musste ich gestern lesen, dass die SBB die Suprise Magazine aus den Bahnhöfen verbannt. Dies hat mich zu einer Reaktion veranlasst, das ich über das Kontaktformular der SBB gesendet habe. Sehr geehrte Damen und Herren Ich beziehe mich auf einen Bericht der NZZ, wonach sie in Zukunft den Verkauf der Surprise Magazine im Bahnhof verbieten möchten. Diesen Entscheid kann ich beim besten Willen nicht nachvollziehen. Es handelt sich hierbei um ein Projekt, welches der Integration randständiger Menschen dient. Es bietet diesen Menschen eine sinnvolle Tätigkeit und einen kleinen Zusatzerwerb. Für mich ist dieses Magazin ein Vorzeigebeispiel des humanitären Geistes der Schweiz. ...

October 11, 2008 · Patrice Neff