Easily Store & Reuse Code With Snippets

If you’re a developer, you’ve probably come across a few snippet managers before. If you haven’t prepare to have your life become a whole lot easier.

For those that are familiar with the idea of saving small sections of code, you’ll definitely want to check out Snippets, an amazing snippet manager that will be an instant must-have for anyone looking to improve or build a personal code database. Below we’ll go over what Snippets is and how to use it to improve your workflow. Then we’ll discuss how it performed during our review process and whether or not you’ll be able to find a decent free alternative. Let’s get started!

What Is Snippets?

screenshot

Snippets Website

Snippets is a powerful application for storing and inserting frequently used portions of code. If you’re a full-time programmer, using an application like this can’t save you countless hours over the long-term spent typing out the same code over and over again.

The basic idea here is to create a central repository for all the snippets that you’ve either created yourself or found online and would like to hold on to. Using a designated keyboard shortcut, you can bring up a quick search menu and insert lengthy code snippets in seconds.

As we’ll see below, the thing that really sets Snippets apart from the competition is the impressive integration with both other apps on your Mac services you might already be using in the cloud.

Your Library

When you open Snippets for the first time, you’ll probably be thrilled to find that you don’t have to start your library of snippets from scratch. The developers have conveniently included a number of useful code snippets written in several major programming languages such as HTML, CSS and AppleScript.

screenshot

Snippets Library

As you can see, the interface is perfectly Mac and therefore instantly usable with little to no learning curve.

Down the left side of the window you’ll see the navigation area that grants you access to all the various snippets in your library. Clicking at the very top will bring up a list of all the snippets, but much more useful is the inherent organization schema built right into the app with zero setup required.

This includes Highlights, Groups, Smart Groups and folders. Highlights are automatic collections of snippets based on language. So if you create a new CSS snippet and a new JavaScript snippet, they will show up under their respective Highlight sections without any action on your part.

screenshot

Groups and Folders

Groups allow you to create collections of snippets unhindered by rules or logic of any sort. Simply create a group and drag in the snippets you want. Groups can optionally be subdivided into folders.

Finally, Smart Groups are automatic collections based on the criteria of your choosing. You setup rules just like you would for Smart Folders in Mail or iTunes.

Adding Snippets

Adding your own code snippets couldn’t be easier. Simply click the New Snippet button near the top of the application and a blank snippet will appear.

screenshot

Adding a new snippet

First you name the snippet, apply labels (tags) and choose your language, then type in the code you want to save and reuse.

The syntax is automatically highlighted based on your selected language just as it would be in your favorite text editor. You can also customize the colors of the text editor to match your preference.

Inserting Snippets

All of the functionality above is quite handy for storing hard to remember code, but the part that really matters for productivity freaks like me is how fast you can insert a snippet and therefore save yourself the time necessary to type it out.

screenshot

Menubar Options

Apart from the dedicated Snippets application interface, there’s a menu bar item that is always easily accessible. No matter what application you’re in, simply hit your designated keyboard shortcut or click on the Snippets menu item and search for the snippet using the name, language, etc.

Alternatively, you can setup a separate shortcut to launch a menu that shows you the groups of snippets that you’ve setup. This is great for users who don’t want to run a search but instead would rather navigate through a list of favorites.

When you find the snippet you want from the list, click on it or hit “Return” and it will be placed at the insertion point of the frontmost application.

I found these quick insertion techniques to be quite satisfactory. The menu bar item seems far away when you’re typing in a text editor so I would not have been happy if I were forced to click up there to bring up the menu. However, the fact that the entire process is accessible from the keyboard speeds up the workflow considerably.

Integration

As I said above, the part that really impressed me about Snippets is the degree to which it integrates with other applications. Along the top there are buttons for quickly mailing your current snippet, copying it to the clipboard and/or editing the snippet in your favorite text editor such as TextMate or Espresso (TextExpander integration was a big win for me).

screenshot

Integration with other apps

Beyond simply integrating with your desktop apps, Snippets allows you to interact with several cloud-based services. First of all, if you want to keep your Snippets synced across multiple computers, you can connect it to your MobileMe account.

My favorite part however is that you can export your snippets to code snippet web apps like Snipplr, Pastie, and Snipt. These code services in turn make it easy to share the snippet via social media and/or embed it into blog post. A quick note to the developers, I would love to seem some Doplr integration here.

My Thoughts

From the moment I opened Snippets, I knew I would love it. The interface, thought not fancy by any means, is highly efficient and easy to navigate, the required workflow is immediately apparent and the system-wide integration is spotless.

This is the part where I would normally insert any complaints but I really don’t have any. I would like for the price tag to be a little lower, but I always say this because I’m such a cheapskate when it comes to software. Ultimately, at $39.95, Snippets is competitively priced in the category of Mac applications of this caliber.

I think the one thing keeping Snippets from a perfect 10 score in my book is the lack of a “holy crap” feature that brings innovation beyond what we’ve seen in other similar apps. The integration aspect I mentioned is definitely a competitive advantage, but not so groundbreaking that most developers would gladly part with forty bucks to experience.

A Free Alternative?

For my fellow frugal nerds out there, you can definitely find a few free options for storing and inserting frequently used bits of text.

By far my favorite free app with this functionality is ClipMenu. It parades as a simple clipboard manager but is in reality so much more. The snippets feature is actually quite awesome and utilizes a pop up window that appears at your cursor providing easier access than a menu bar item (which is also present).

screenshot

ClipMenu

Keep in mind that the features here won’t even approach that of Snippets. If you want something that’s a lot closer to Snippets’ code library organization functionality, check out jCodeCollector.

Conclusion

To sum up, Snippets is a stellar application for storing and inserting frequently used portions of code. Just about every language you could want, from AppleScript to CSS, is fully supported with smart text highlighting.

Organizing your library is completely effortless and inserting a snippet is a fast and efficient process. Ultimately, I can’t recommend a better code snippet app.

If you disagree, leave a comment below and let us know what snippet apps you use and why they’re better than Snippets. As always, we’d definitely love to hear about more free alternatives.


Summary

Snippets is a personal code repository that allows you to save and quickly insert frequently used bits of text formatted in any major programming language.

9
  • http://www.gotwebsites.co.uk James

    I’ve downloaded the trial and if it’s half as good as people say it is then I’ll be buying it soon! I haven’t been able to find much about integrating it with Coda though.

  • Jenn

    Just bought this before it came out. Thanks for the write up :)

  • Pingback: Snippets – Store and Reuse Code, Clipboard Manager redefined « NightLion

  • Brett

    As an awesome alternative try out Snippet ( http://fuelcollective.com/snippet ) for $12.95 from Fuel Collective. They make several other excellent tools as well.

    • Tyler

      I second this. Snippet is great. You can sync your snippet library with dropbox and share it cross computer and share the same snippet library with someone else with live updates.

      I highly recommend Snippet by fuel collective over Snippets

      • http://www.snippetsapp.com/ Vladimir Prudnikov

        You can sync Snippets library over MobileMe and Dropbox (or any mountable location such as private FTP using Expandrive for example). Moreover, you can share just a part of your library with your co-workers (different groups to different people) using datastores ( read more here http://www.snippetsapp.com/blog/snippets-1-1.html)

  • adrian

    considering envato just purchased snipplr and I believe snippets is in some way affiliated with snipplr, wouldn’t this be an ad for a business partner

    • http://envato.com Collis Ta'eed

      Hey Adrian, good question, we did indeed purchase Snipplr recently!

      Snippets contacted us to say that they had integrated their product with Snipplr, so we announced it on the Snipplr blog, and I recommended they contact Mac.AppStorm’s editor to get reviewed as the product sounded pretty good.

      So I don’t think that constitutes an ad for a business partner. I recommend lots of things to be covered on our blogs, and often it’s just when people contact me (Hopefully that doesn’t get me a barrage of new email :-)

  • Andrew

    I just use the built in feature in Coda. This seems cool, though.

  • Pingback: | David Sparks

  • http://novastormsoftware.com Justin Mrkva

    This is my snippet manager of choice – definitely the best available. I had Fuel Collective’s Snippet before but I just found that I needed something with more flexibility and a more library-like interface. I also used to use Code Collector Pro but found the interface for inserting snippets just didn’t cut it (pun intended).

  • http://jonathanlafleur.ca/ Jonathan Lafleur

    I use Sublime who have a great snippet tool feature.

theatre-aglow
theatre-aglow
theatre-aglow
theatre-aglow