LearnCross-platform snippet syncing with Dropbox, TextExpander and Breevy

Being device independent means being able to code in any device or platform. One of the things you might want across devices is access to your code libraries. One way to do it is using a couple of macro tools combined with Dropbox.

Lately, I’ve been toying around with the idea of platform independence. It shouldn’t really matter wether I’m working on a Mac, PC, a tablet or whatever…I should be able to start a project on one device and continue it on another. I’m already doing that to some extent with my iPad and Dropbox. It’s replaced my laptop as the device of choice when going to meetings. It’s easier to take the iPad than to have to undock from all of my cables. The device keyboard in underpowered, but perfect for quick notes, media or web access. I’ve been wanting to navigate between Macs and PCs for development projects, but I’ve been missing quick access to my code library in both platforms.

The Problem

I have a lot of small pieces of code that I reuse from time to time to speed up my development. Some of them are stored as shortcuts so I don’t have to type a bunch of code when I need to create a basic query or look up a grep pattern. I tried using the tools inside a lot of editors to handle this, but I use different editors for different projects. So I find it better to use a tool like TextExpander that makes my macros available to all programs. The great thing about TextExpander is it’s ability to share preferences via Dropbox for syncing accross different machines, but it’s a Mac only solution.

Thankfully TextExpander has a cousin on the PC side called Breevy. The programs are amazingly similar and Breevy is made to complement TextExpander. One of the key features of Breevy is it’s ability to use Dropbox to keep things in tune with your Mac’s TextExpander snippets.

Taking care of things on the Mac Side

The setup for this is pretty easy. First, make sure you’ve downloaded and installed Dropbox on both machines. You’ll want to start things off on the Mac first so make sure you download TextExpander. It comes with a few default shortcuts, but you’ll probably want to type some of your own to get started.

TextExpander on the Mac

Once you’ve set things up on the Mac, you’ll want to configure TextExpander to share it’s preferences. Click on the preferences icon and choose the Sync tab. Then, click on the Dropbox radio button. Optionally, you can choose to share your snippets with other devices on your network. You can use that to sync my shortcuts to an iPad or iPhone with the mobile version sold separately called TextExpander Touch.

Changing preferences in TextExpander

Setting up on the PC side

You can use these settings to use the same TextExpander library on multiple macs, but if you’re going to share with a PC, you’ll need to download Breevy. Make sure you’ve completed the installation of Dropbox on your PC and downloaded and installed Breevy. Once you’ve done that, head on over to Breevy’s preferences.

Changing preferences in Breevy

Click on the Dropbox Sync tab of the preferences and then check Enable Dropbox sync… You’ll then need to locate your Dropbox folder. Breevy will do a great job of detecting where the folder is, but you can customize it if you want to. Finally, make sure you check Enable TextExpander mode to make sure the database closely matches in both programs.

Some final thoughts

This solution works pretty well, but I wouldn’t go crazy editing shortcuts between machines. Because of some latency in the way Dropbox syncs,things can get out of whack and Dropbox might get confused with too many fast cross-platform edits. If you’ve already running TextExpander, I would recommend you setup and backup your Database BEFORE you do this. Also, use Dropbox as your backup because it allows you to revert back to an earlier revision if things go haywire. I’d love to hear about any cross-platform, tablet to Mac to PC tips you’d be willing to share.

19 Responses to “Cross-platform snippet syncing with Dropbox, TextExpander and Breevy”

  1. snippets me has both mac and windows version with its own cloud sync
    http://snippets.me

  2. Hugo Solar on July 17, 2011 at 5:55 pm said:

    Great article! but do you know if exists any linux app to do that?

  3. Hugo Solar on July 17, 2011 at 5:55 pm said:

    Great article! but do you know if exists any linux app to do that?

  4. You guys should take a look at QSnipps. It’s a small cross-platform snippet management tool what works pretty well with dropbox syncing: http://www.qsnipps.com

  5. Harolastro smith on July 2, 2011 at 3:53 am said:

    Dropbox is one of the best programs I’ve used, its simple, does what you need and yes you can trust it.http://maxcleansefacts.com/

  6. Harolastro smith on July 2, 2011 at 3:53 am said:

    Dropbox is one of the best programs I’ve used, its simple, does what you need and yes you can trust it.http://maxcleansefacts.com/

  7. Mark underplank on July 1, 2011 at 4:14 am said:

    As far as copy and paste synergy+ is a software/netowrk KVM that foes copy and paste. Works windows/linux/mac .. sometimes a little buggy, but 95% the time great!

    Do you know of text snippet program on linux that is compatible with the Breevy and Textexpander software?

    • planetoftheweb on July 1, 2011 at 9:41 am said:

      Haven’t booted up a linux install in a while. There’s a few similar programs, not sure there’s something compatible, but there’s kbd-mangler (http://kbd-mangler.sourceforge.net/) and  Autokey (http://code.google.com/p/autokey/)

  8. planetoftheweb on June 30, 2011 at 9:21 pm said:

    Some additional notes about this article:  
    I wrote this article on my PC using eTextEditor (http://www.e-texteditor.com/) and using MarkDown code (http://daringfireball.net/projects/markdown), but needed some Mac and PC Screenshots with the circle highlights.

    I used imgur (http://imgur.com/) to transfer my PC screenshots to my Mac, where I used Little Snapper (http://www.realmacsoftware.com/littlesnapper) to do all of the highlight circles for both platforms. Imgur has a nice drag and drop interface so you can transfer things quickly between the platforms and it provides quick URLs you can put on your posts (thanks to Nick Pettit for the idea).

  9. planetoftheweb on June 30, 2011 at 9:21 pm said:

    Some additional notes about this article:  
    I wrote this article on my PC using eTextEditor (http://www.e-texteditor.com/) and using MarkDown code (http://daringfireball.net/projects/markdown), but needed some Mac and PC Screenshots with the circle highlights.

    I used imgur (http://imgur.com/) to transfer my PC screenshots to my Mac, where I used Little Snapper (http://www.realmacsoftware.com/littlesnapper) to do all of the highlight circles for both platforms. Imgur has a nice drag and drop interface so you can transfer things quickly between the platforms and it provides quick URLs you can put on your posts (thanks to Nick Pettit for the idea).

  10. atnbueno on June 30, 2011 at 8:37 pm said:

    Cross-platform tips? How about copy&paste text between Macs and PCs? The idea is the same: using Dropbox as synchronizer, but this is much simpler than your code snippet solution (very nice, BTW) and can be done with a couple of scripts: http://hints.macworld.com/article.php?story=20110617041836290

    • planetoftheweb on June 30, 2011 at 9:18 pm said:

      This sounds good, but there is a bit of assembly required with that solution. I like the idea of copy and paste between platforms.

  11. slashrsm on June 30, 2011 at 7:33 pm said:

    What about SparkleShare (http://sparkleshare.org/). It’s a great tool that uses GIT to synchronize files.

    • planetoftheweb on June 30, 2011 at 8:13 pm said:

      Looks like a cool project, but it doesn’t have solid Windows support yet, plus it seems more like a file sharing/sync’ing service. I think Dropbox is more solid for that purpose.

      • slashrsm on July 1, 2011 at 7:34 pm said:

        I agree…. Since SparkleShare looks a nice and promising project, I hope it will be developed to a stage when it will be really usable (Win, Android, iPhone support; various storage backends, …)!

  12. Jonathan on June 30, 2011 at 7:37 am said:

    I use Phrase Express for this task which is not only free for home use but also much more powerful:
    http://www.textexpanderwindows.com

    • planetoftheweb on June 30, 2011 at 9:41 am said:

      Good point Jonathan. Phrase Express is pretty cool, but the syncing isn’t live like with Breevy, which will see changes and update all of your groups as they change. It’s more like the iPad Import option with TextExpander Touch, which is cool, but if you have a lot of groups is a bit cumbersome. Still though, if you don’t update your snippets often Free is better than $30.

Leave a Reply

Learn to code with Treehouse

Start your 7 day free trial today and get access to hundreds of video courses in web development, design and business!

Learn more