Every so often, I have occasion to share my bookmarks with a co-worker. But often, I only want to share a subset of my bookmarks. I'm sure there are a dozen programs you can download to do this for you, but I felt like writing some Python today. This script is the result of my efforts. Save this script as export_bookmarks or some such, and make it executable (chmod 755 export_bookmarks). Then run it like so:
% export_bookmarks > bookmarks.html
If you wish to export just a subset of your bookmarks, just provide the names of the folders (one or more) containing the bookmarks you wish to export, like this:
% export_bookmarks Python Perl > bookmarks.html
The resulting bookmarks.html file can be imported into Safari (via Import Bookmarks under the Debug menu). Your mileage may vary...
Mac OS X Hints
http://hints.macworld.com/article.php?story=2004092916004989