Showing posts with label diary. Show all posts
Showing posts with label diary. Show all posts

Thursday, November 4, 2010

created my personal calendar 2011

Ran a couple of home-brewed perl scripts.

After I ran them last year I started coding my $HOME/diary in UTF-8, and obviously my scripts don't deal too well with UTF-8, they were written for Latin-1, but luckily enough (and that's the major advantage of UTF-8!) they don't break badly enough. "Of course" there is no time right now to teach these scripts, how to properly deal with UTF-8, but a few changes around him helps well enough.

I keep delaying this task every year, but it has to be done. I really fear every year, processing this task takes many, many hours. It only took like 2 hours this year / today.

Of course it's my fault, my scripts don't deal well with UTF-8. I am rather sure, Perl / Perl5 can deal with it just as well as other modern programming languages. So put it on my laziness!

Tuesday, May 25, 2010

creating diary entries from procmail LOGFILE entries

Incoming e-mail messages may be worth getting recorded in a diary, of course most of them are not, do you agree?
Quite some times I manually create diary entries from my procmail LOGFILE.
I should have written a script to do that a long time ago. Now I did. That effort was really, really little, but I like the results.

Update / 2010-07-23:
I used to copy the entries from that log to my diary, and then a little later I usually wonder, which ones got already processed and completed. So what was missing, was just a little aid, but it looked difficult so solve for a while.
Today I introduced something new and the entry now looks like this:
23 Jul 2010
        09:56:49 [_] From: abc@def.com;
That's wicked cooled, isn't it? Yes, I know.

Thursday, October 29, 2009

creating phone book and diary entries from incoming calls on my router

If you read this title, how mad do you think I am? Honest!

Alright, "as you know" (so of course this article only applies to some sort of computer nerds), my router is a FRITZ!Box 7270, it's also the base station for my (wireless) phones, and a lot more ... -- certainly one of my most important toys or gadgets. And I have 2 of them, one for at home, one for anywhere outside, where I can only connect to the Internet through UMTS.

So alright, back to the title of this article!

  • It's nice to record your incoming and outgoing calls in your diary, right? (my diary is emacs style)
  • It's nice to get something descriptive displayed on your phone, when somebody calls, right?
  • It's nice to extend your phone book through time as easily as possible, right?

Well, my router is running Linux as its operating system kernel, and BusyBox on top of it. On each incoming phone call it runs a shell script with a few parameters, of course the caller's phone# (if available) and also the callee's phone#. (I do have more than one phone#, and why not also record the called phone#, just for the record?) It tries to associate a name with the caller's phone#, if there is a matching entry in the phone book.

Quite a while ago I started implementing such a shell script, and obviously (as it is almost an ordinary (bash) shell script), I can develop and test it on any of my computers, that can run shell scripts, like any of my openSuSE computers, any WinXP computer running cygwin, a Mac running OS X, ... . Yes, I cannot create a full blown shell script, I will not pipe a lot through one-liner perl or ruby scripts on my router, but still: it's a handy and useful, not so tiny shell script.

So far it appears to me, as if no such executable gets called on the router for outgoing calls, but I can still mimic this behaviour by calling that script on my main development box.

Having said this, my script (fritz_box_calllog.sh) fulfills all the requirements, that I listed above in that bullet list.
For incoming calls without caller id and/or without a matching entry in the phone book it creates a piece of XML text, that I can paste into my FRITZ!Box XML phone book, and where I can fill in a phone# and a name or any descriptive text, so next time, I want to dial that phone# myself, I can select it from the phone book. And maybe another time that person will call you with caller id, and then you will be able to greet that person with her/his name. Wouldn't that be nice?

The implementation of this software also got inspired by Matthias Hühne's "Dial!Fritz", that I run on my iPhone. But of course his software is far completer and nicer, and it's well integrated.