The profession of designer is not that of an artist nor an aesthetician; it is that of a specialist in semantics.
— P. Starck
Personal weblog by Logan Raarup.
I'm an entrepreneur, ruby developer, engineer and guitarist.
Check out some of my stuff:
Twitter
GitHub
coookin'
Softinnovator
The Sickboy Method
The profession of designer is not that of an artist nor an aesthetician; it is that of a specialist in semantics.
— P. Starck
Look at me. Now, look at your man. You’re on a boat with The Man Your Man Could Smell Like.
It’s not about pop culture, and it’s not about fooling people, and it’s not about convincing people that they want something they don’t. We figure out what we want. And I think we’re pretty good at having the right discipline to think through whether a lot of other people are going to want it, too. That’s what we get paid to do. So you can’t go out and ask people, you know, what’s the next big [thing.] There’s a great quote by Henry Ford, right? He said, ‘If I’d have asked my customers what they wanted, they would have told me ‘A faster horse.’’
— Steve Jobs quoted in You Can’t Innovate Like Apple
I use Dropbox to sync and backup most of my stuff. Out of the box, Dropbox makes it easy to sync documents, photos, music etc.
However, I also wanted it to sync application preferences between my Macs. This can be done in a rather simple way, using a Launch Agent and a simple Ruby script.
This is a basic overview of how it works:
Let’s take a look at how to implement this.
Folders
We need to setup a Dropbox folder for mirroring the preferences. I created a folder called Preferences in my dropbox. Also, I have a subfolder called Scripts for storing the Ruby script and a copy of my Launch Agent for installation on other computers.
~/Dropbox/Preferences~/Dropbox/Preferences/ScriptsIf you want to use other folders for your setup, make sure to correct the paths in both the Ruby script and the Launch Agent.
The Ruby Script
This script performs the actual mirroring of modified files. Any preference files that should be synced must be included in the preference_files array. As you can see, this script is set up to sync preferences for the TextMate, Transmit and Terminal applications.
The script should be placed in the file ~/Dropbox/Preferences/Scripts/copy_plists.rb.
The Launch Agent
The Launch Agent is responsible for monitoring the preference folders. It consists of a plist file, represented as XML in the following code section.
Install the Launch Agent by copying the XML into the following file:
~/Library/LaunchAgents/com.dropbox.preferences.plist
Make sure to replace all [USERNAME] entries in the XML with your actual Mac OS X username. If you have Xcode Tools installed, you can also edit this file using the Property List Editor application.
That’s it. I have been using this setup for about a year, and it has been pretty robust this far. Got any ideas for improvement?
Note: This setup is only necessary when you need to sync individual plist files. If you want to sync entire folders (e.g. ~/Library/Application Support/Textmate), you can create a symbolic link to the folder inside your dropbox.
Update April 23
Tumblr’s questions feature doesn’t allow the author to reply. Answering some questions related to this post:
“Why not just move the Preferences folder to your Dropbox then make a symlink?”
This should work as well, however I found that I only wanted to synchronize settings for a few apps. Some apps have settings, which you’d like to have different between systems.
“What would be benefit of having it this over making the actual plist file to a symbolic link and copying it to the dropbox folder?”
This was also my initial approach. The problem is that a lot of applications recreates the plist file instead of writing into the existing file, thus removing the symbolic link. That’s basically why this setup was needed at all.
“I don’t know anything about Ruby or Rails, but did you really need to put the ‘Copied to’ line in an if/else statement? And is ‘elsif’…?”
Sure, the ruby script could be refined and made more slick. I just needed a quick solution and it works, so that’s good enough for now :)
“Does it work to symlink the plist files into your Dropbox? If not, what about a hard link? Seems the script should definitely be unnecessary.”
Unfortunately, Dropbox will overwrite the symbolic link with a regular file upon update. I haven’t tested hard links yet, but please let me know if you do. For more information on symbolic- and hard linking files in your Dropbox, and the related issues, see: http://wiki.dropbox.com/TipsAndTricks/SyncOtherFolders#OSXandLinux
Without the shades, they might have to face the terrifying prospect of actually speaking to one another.
(Photo: Dean Kaufman; Dwell, September 2009)
Unhappy Hipsters: Great blog - check it out!
Source: unhappyhipsters
Great tool for saving stuff you would like to read later. I used to bookmark articles and such, but it gets hard to manage. I can also recommend the accompanying iPhone app. You probably know about it already - but if you don’t, check it out.
It’s about time for a code post :)
I ran into some issues with ActiveRecord I18n error messages when using Authlogic. Apparently Authlogic looks up the translations during initialization, so if you change locale later on with I18n.locale= (e.g. in a before_filter), any ActiveRecord error messages will still appear in the default locale.
This issue is currently listed in the GitHub project, however I needed a quick unobtrusive fix until it’s corrected in Authlogic. I’m sharing it in case others run into this problem.
This is a simple and very delicious recipe. I know it’s a bit off-season as it’s not really winter-food, but I’m just starting to look forward to warmer weather :)
The first step is to cook up some flatbread. This is a very simple process of making a flatbread dough with flour, yeast, water, oil and salt. I usually add some rosemary or other herbs to the dough. Roll it into pancakes and cook it on a hot pan! Check this recipe for a more detailed walkthrough.
Next is the cream which ties it all together. It’s made with sour cream, crumbled feta cheese, chopped chives, salt and pepper. Very simple, about 50/50 sour cream and feta.
I usually fry some chicken fillets, seasoned with rosemary, garlic, lemon, salt and pepper. But any other meat and spices should do just fine as well.
Serve it with some tomatoes, cucumber and romaine lettuce. Roll it up and eat with your hands - Mmmm…