Damon Cortesi's blog

Musings of an entrepreneur.

Bloglines, I Don’t Want to Fight Anymore

| Comments

I mentioned recently that Bloglines implemented shortcut keys and what a wonderful feature it was.

Well it still is a wonderful feature, but unfortunately for me I’ve been experiencing a fairly critical bug ever since. Reading my subscriptions with the shortcut keys works great, however when I go back to using my mouse I will frequently click on a feed that has new items only to be greeted by no actual articles…just the title of the page. I then have to go to the corresponding site in order to read the new articles that Bloglines (accurately) reported. This is becoming increasingly frustrating as it really decreases my efficiency for browsing through my feeds.

I’ve emailed Bloglines support, but only received a reply requesting my OS and browser (Firefox on both XP and OS X). I haven’t heard back since, so I can only assume not many other people are having this problem. It’s really unfortunate, though, as I love using Bloglines but this is really making it unusable for me. I’ll have to start looking around for other options. I’d try Google Reader, but haven’t seen good reviews about that yet. Maybe if I’m lucky, I’ll get an invite to FeedLounge - from what I’ve heard from the blogs, people are pretty excited about it.

But Bloglines…I don’t know why you’ve chosen to play this cruel trick on me. Things between us were so good and then you went and did…this. I’m a forgiving man…if only you would not forget about my new articles! :-(

Happy Halloween

| Comments

Happy Halloween - it’s a rainy, foggy, spooky night here in Chicago as you can see below. halloween_05/IMG_1986

I was busy saving the matrix this weekend…I had a pretty good time. :-) halloween_05/DSC00090

The Air Smelled Distincively of Celebratory Cigars…

| Comments

…as the White Sox rolled through downtown Chicago. I wandered down to the parade during lunch today to check out the parade and rally the city was throwing for the Sox. It was insane! White Sox Parade

The streets were packed, as you can see. People were climbing over everything - signs, street posts, planters, bus stops, TV vans…anything to get a better glimpse over the sea of people that swarmed the downtown Chicago area. I happened to settle down just under the L at Lake and La Salle when the parade started going by. One of the floats managed to nail the bottom of the L tracks as it went under, temprorarily holding up the parade. Luckily nobody got hurt and they got it unstuck and were on their way again. The players also had to duck as they went through as they were on the top of double-decker busses…it was pretty close. There was also confetti and shredded sun-times newspaper (the best black and white confetti one can get on short notice, I suppose) all over the place.

It was a pretty crazy scene, but a lot of fun to be down there amidst all that. The best was this little girl whose father put her up on a walk sign. She eventually wanted to get down but her father had her sister on his shoulders and couldn’t get her because there were so many people. She started pouting for a bit, but then started posing for cell-phone photographers such as myself. ;)

Girl on Walk Sign

I have a few more photos on flickr.

Lazy

| Comments

I just realized I’ve only made two posts for the entire month of October…wow. Sorry about that…guess I’ve been busy with life. Lots of busy weekends - vacation, work, having fun. I have lots of pics to post so hopefully I’ll get around to that sometime. :)

Bloglines Adds Shortcut Keys

| Comments

Some of you may know that I use Bloglines to read my rss feeds. I don’t know how long this has been enabled, but I just saw tonight that Bloglines has added shortcut keys, ala Gmail!

Bloglines Shortcuts

I’ve only used it once and it’s already making reading my feeds so much easier!

Thank you, Bloglines! This rules! No more uncomfortable scrolling with my trackpad/nubbie/scrollie wheel.

Hrm…I wonder if this has anything to do with Google releasing Google Reader the other day… ;-)

Decimal Math in Shell Scripts

| Comments

I was reading about inserting random delays in cron jobs and was surprised when I saw this code to get a random number:

1
2
3
4
5
# Grab a random value between 0-240.
value=$RANDOM
while [ $value -gt 240 ] ; do
  value=$RANDOM
done

I thought, there’s got to be a better way to get a random number within a specific range. I mean, that kind of seems like a waste of CPU cycles, particularly when $RANDOM can be anywhere in between 0 and 32767. And a quick test verified that was exactly the case. On average (out of 500 samples), using that method to get a random number below 240 requires 134 attempts. Not a horrid performance impact, but enough to get my anal retentive brain in a twist.

My first thought was to use the expr command to do some simple math to properly adjust the $RANDOM variable into the desired range. But soon enough, I realized the expr only deals with integers…bummer. Looking around to see what else I could use for decimal math, I eventually came across the dc command - a reverse-polish desk calculator:

1
echo -e "6\nk\n$RANDOM\n32767\n/\n1\nk\n240\n*\np" | dc | cut -f1 -d.

This definitely seems to be faster.

time echo -e “6\nk\n$RANDOM\n32767\n/\n1\nk\n240\n*\np” | dc | cut -f1 -d. 104 real 0m0.003s user 0m0.003s sys 0m0.002s COUNT=0; time while [ $RANDOM -gt 240 ]; do COUNT=`expr $COUNT + 1`; done; echo $COUNT real 0m0.445s user 0m0.158s sys 0m0.297s 295

Update: After pondering the comment below, I realized this can be done in bash by using factors of 100 to resolve the integer math issue. There are several ways to do this, but here are a couple options:

1
RAND1=`expr $RANDOM \* 100`; FACTOR=`expr $RAND1 \/ 32767`; DIV=`expr $FACTOR \* 240`; RESULT=`expr $DIV \/ 100`;
or
1
expr $(expr $(expr $(expr 9264 \* 100) \/ 32767) \* 240) \/ 100

They appear to take about the same time, around 0.050s real time and 0.015s sys time.

This.ToDo()

| Comments

There are two things I really need to get accomplished within the near future…at least on the tech side of my house.

  1. Finally settle on a host OS for my websites. I’ve got a few on Debian right now and one on Gentoo, but running two MySQL databases and two Apache daemons is really starting to kill my hosting server and the downtime of my blog last week was the result of said resource exhaustion. I think I’m going to settle on Gentoo for right now for it’s virtual hosting capabilities, for better or for worse. But it will take a lot of work to recreate the setup I have.
  2. I’ve had a sweet little perl script lying around the past couple years that draws pretty, but limited graphs. Stumbling across Blender, an open source 3D modeler has renewed my interest in the script as it could be much more effective with an animated 3D model! I should probably work out the kinks first, but half the kinks were with the graphing software I was using.

Of course, both of those are no easy task, especially when the rest of life comes into play. But, hopefully, I can have at least one of those wrapped up in the next month. I’ll give the other until the end of the year and hope that I find the motivation one night to pound through it.

Gentoo, a T42, and a Dell 2005FPW All Walk Into a Bar

| Comments

I just spent the past three hours or so trying to get my 2005FPW monitor working on Gentoo with my T42 docked. It was not an easy process and I have to go to bed, but there were a couple things that pointed me in the right direction.

    <li><a href="http://www.tuxme.com/node/544">Ubuntu on a T42</a>, specifically the Video portion, and even more specifically the MonitorLayout option actually got the monitor functional.</li>
    <li>The <a href="http://www.horstmann.com/linux-thinkpad-t41p.html">ModeLine from this page</a> gave me a proper resolution.</li>
    

This FreeBSD post on dual monitors also helped quite a bit, but it was those two links above that made it perfect.

Now I have to crash. Pulling the night shift tomorrow, that’s why I’m up nice and late. :-)

I’m Back!

| Comments

Well, after 1,100 miles of driving, a camp site overlooking the Pacific, a deer carcass…or what was left of it, beautiful sunsets, good times, good friends, and a speed tour of Temecula’s Wine Country, I’m back home!

I’ve got a bunch of pictures to upload later, but I had a great time camping and hiking in Big Sur.

^D

| Comments

Disconnecting for a bit… See you next Monday! :)