New ColdFusion Builder Extension: GistCreator

This post is more than 2 years old.

A few months back I switched to using Gists ( for my code samples. For the most part it just worked fine. I did have to do a bit of work to get it right under jQuery Mobile, but outside of that I'm happy with the change.

Now that I've made the switch, I find myself making a heck of a lot of gists. I tweeted earlier today that it would be cool if my editor would make it easier to create them. Right now I spend my time using Sublime Text 2, ColdFusion Builder, and, um, another editor. @bittersweetryan pointed out an excellent plugin for Sublime. That worked great. But I thought it would be fun to build an extension for CFBuilder as well. So I did it. Because I do that now. I love my job. A lot.

GistCreator works with both files and in the editor. To create a Gist out of a file, just right-click:

Or - you can select text in the editor and create a Gist out of it:

You can also just right click in a file, and if nothing is selected, the entire file is sent.

Once done - the extension returns the URL:

And that's it. Right now the extension only creates public Gists and doesn't allow you to name them, but it should work fine for now. Also, it is a bit brittle. If your authentication changes then the extension will not handle it well. As always, I'm open to folks checking it out and adding features.

Fork it here:

Raymond Camden's Picture

About Raymond Camden

Raymond is a senior developer evangelist for Adobe. He focuses on document services, JavaScript, and enterprise cat demos. If you like this article, please consider visiting my Amazon Wishlist or donating via PayPal to show your support. You can even buy me a coffee!

Lafayette, LA

Archived Comments

Comment 1 by andy matthews posted on 5/30/2012 at 1:45 AM

Couple things you should consider adding.

1) Gists allow a description and a file name. Consider pulling the filename from the currently focused file.
2) In addition to the results displayed on the dialog box, consider adding the script tag (that's what most ppl want anyway).

Otherwise great job. This is a great idea for an extension.

Comment 2 by Raymond Camden posted on 5/30/2012 at 1:46 AM

Going to answer in reverse order:

2) I think the embed makes a lot of sense.
1) My issue with filename/desc is that it slows the user down. I like how it "just happens" here. Sure it would add a grand total of one more second...

Well... ok. I'll consider it. In fact, I'm pretty sure I will. I just want to ensure you can hit "Ok" on that form w/o entering anything at all. (Filename already defaults.)

Comment 3 by Raymond Camden posted on 5/30/2012 at 2:06 AM

I support returning the embed url now. The last screen cap above is a bit out of date. It will include the embed tag in a nice text box you can cut and paste.

Comment 4 by Steve W posted on 5/31/2012 at 4:11 AM

Thank you. I am a newbie to Git and this is pretty cool. I like the fact that it just works.

Comment 5 by Raymond Camden posted on 5/31/2012 at 5:29 PM

Thanks. I'm adding another tweak today - the ability to set private/public, description, and change the filename.

Comment 6 by Steve W posted on 5/31/2012 at 6:55 PM

One quick, cosmetic recommendation. Next time your doing an update, can you wrap each form field in a paragraph tag instead of the br? I did this before my second install and it makes it look so much nicer.

Comment 7 by Raymond Camden posted on 5/31/2012 at 6:56 PM

You mean the form for auth info? I can - and I'm adding a new form now.

Comment 8 by Steve W posted on 5/31/2012 at 7:42 PM


Comment 9 by Raymond Camden posted on 5/31/2012 at 7:44 PM

Check out the new version.

Comment 10 by Michael Santoroski posted on 5/31/2012 at 9:27 PM

Can you pull your gists in from Builder?

Comment 11 by Raymond Camden posted on 5/31/2012 at 9:34 PM

No. In theory, we could do. Extensions can do Views too. So it would be possible to build a View of your Gists. I could even make it so you could click the Gist to inject it into the current document.

Would there be a desire for this?

Comment 12 by Corey Butler posted on 6/14/2012 at 8:00 PM

Cool little extension. Just as a side note, I believe this same functionality is offered via the Github plugin for Mylyn. Or perhaps it's part of the Aptana suite. I have both installe and I forget which comes with which. Anyhow, I thought I'd mention it... it supports gist creation, but it also integrates Github issues right into any Eclipse IDE task manager, along with other convenient Git-oriented features.

Comment 13 by Raymond Camden posted on 6/19/2012 at 5:52 AM

Ah, nice, thanks for sharing that.

Comment 14 by John Farrar posted on 4/12/2014 at 8:11 AM

Using a tool called GistBox. Would love to see very similar features offered inside CFBuilder. Would love all this and more for free... LOL. Do you still have a wish list. Have not heard you mention it in awhile.

Comment 15 by Raymond Camden posted on 4/12/2014 at 7:44 PM

My wishlist is linked to from the right side. :)