Archive for October, 2008

Foxmarks – Firefox Bookmark Synchronization

My desktop boxes at work and home both run Ubuntu Linux, I have a Mac Mini attached to my TV and a Mac Powerbook for when I travel. If I’m headed to my company’s co-lo I take along a company laptop running openSUSE Linux. On all of these systems I run Firefox as my primary web browser.

Until recently I used a tool called BookmarkBridge to try to keep my ever-growing list of bookmarks somewhat synchronized. I say “somewhat” because the the process is manual, requiring copying the bookmark files to one computer, doing the merge, and then copying the files back out to the individual computers that need to be updated. Unfortunately the last time I tried using BookmarkBridge to merge bookmarks from multiple computers I ended up with a file of all of the bookmarks from one computer — the new bookmarks from the other two computers were over-written.

I needed a better solution.

A few months ago I found a better solution when I discovered Foxmarks, a Firefox plugin that keeps all of your bookmarks automatically synchronized all of the time. If I add a bookmark on one computer it shows up on the other four. If I move a bunch of bookmarks into the same folder on one machine the bookmarks show up in the same folder on all of my other machines. No fuss, no muss. Brilliant.

It’s really easy to install and use. Open up Firefox, go to the Foxmarks web site and click the install button on their home page. When you restart Firefox you’ll be asked to create a Foxmarks user account (name and password) and you’ll create your initial set of bookmarks from your browser’s current set of bookmarks.

To sync your bookmarks with another computer running Firefox just install the Foxmarks plugin on the second computer. This time when you restart Firefox enter your Foxmarks user name and password when prompted, then decide if you want to merge the bookmarks on the second computer with your current bookmarks or if you want to replace the bookmarks on the second computer with the bookmarks currently stored in your Foxmarks account.

That’s it. Once its set up your Firefox bookmarks on both computers will remain in sync all of the time.

At this time — Foxmarks only supports Firefox. If you need to merge bookmarks with a copy of IE, Safari, Opera, Seamonkey or Konquerer, you’re out of luck.

If you don’t like the idea of storing your bookmarks on someone else’s system you can run your own Foxmarks server. Foxmarks should run with any WebDAV server and is also compatible with the Chandler Server (Cosmo).

Hope you found this useful.

Comments (3)

Change your Skype availability status on Ubuntu via cron

I used Skype when it first came out and then stopped because there were only a few other people I knew who used it regularly. Since they were all in my local calling area, if I wanted to talk to any of them for free I could just use a phone.

I just started using it again — for work — to talk with customers and consultants who do not live in the Bay Area. However, I found that my Thursday telecommute days were causing problems: Skype would be running on my work computer and people trying to call me would get ring-no-answer because I was actually at home.

Turns out you can start and stop Skype via cron the same way you can start and stop Pidgin Instant Messenger via cron, you just need to set a few environment variables and it works great.

First create the script ~/bin/export_x_info which looks like this:

#!/bin/bash
# Export the dbus session address on startup so it can be used by cron
touch $HOME/.Xdbus
chmod 600 $HOME/.Xdbus
env | grep DBUS_SESSION_BUS_ADDRESS > $HOME/.Xdbus
echo 'export DBUS_SESSION_BUS_ADDRESS' >> $HOME/.Xdbus
# Export XAUTHORITY value on startup so it can be used by cron
env | grep XAUTHORITY >> $HOME/.Xdbus
echo 'export XAUTHORITY' >> $HOME/.Xdbus

Create this script, type chmod 700 ~/bin/export_x_info so you can execute it, then execute it, then add it to System > Preferences > Sessions > Startup Programs so it will execute every time you start your computer and record the latest session address and XAUTHORITY value.

This script creates a 4-line file ~/.Xdbus with the current session address and XAUTHORITY value. By sourcing this file in the crontab file your scripts can now use dbus to send messages to X-Windows applications. To start and stop Skype at work I added these lines to my work computer’s crontab file:

# Skype on/off
00 09 * * Mon,Tue,Wed,Fri source ~/.Xdbus; /usr/bin/skype &
30 17 * * Mon,Tue,Wed,Fri killall skype

On my home computer I have:

# Skype on/off
00 09 * * Thu source ~/.Xdbus; /usr/bin/skype &
30 17 * * Thu killall skype

So on Thursdays when I telecommute Skype is running at home, the rest of the week it’s running at my office, and at night it’s turned off so customers aren’t calling me in the middle of the night.

When Skype isn’t running other users see your status as “Offline”. When cron restarts Skype it starts up with the same status it had when the process was killed. I just leave my status set to “Online,” so when cron starts Skype it shows everyone that I’m online. When cron kills the Skype process at the end of the day my status changes to “Offline” and people can’t call me.

Hope you find this useful.

Comments (1)