Question

I would like a general purpose code snippets library, that I could use to store bits of code for any language, organized in folders. When any developer on the network adds a snippet, it should get transferred to others.

How can I do this simply? Any app that could be used for sharing libraries of text should be okay too.

Was it helpful?

Solution 4

Code Warehouse is the most extensive source code snippets manager. Code Warehouse is multi-user ready, which means that an organization’s entire development team can share a central code library and benefit from code that is already written and tested.

alt text http://www.xcca.com/cwbig.png

OTHER TIPS

That's called "a wiki".

We use a Sharepoint Wiki page for exactly this purpose ... that way code instructions and examples can be included in the same place.

A wiki is definitely the way to go but why stop there? Why not go with an issue tracking system that adds wiki functionality?

I have first hand experience with Trac and Redmine and openly recommend both of them. We've recently switched from Trac to Redmine where I work and I think I like it a little more than Trac, and use the wiki functionality almost everyday.

Update:

If you are looking for something smaller scale, there was a previous discussion here on SO that looks like it has some interesting links.

You might be interested in snip2code.

enter image description here

They do exactly what you are talking about... searching, collecting and sharing snippets of any language. It solves the problems I had for similar issue.

Hope it may help

Please have a look at gist.github.com. This is definitely much better than a wiki sharepoint. Plus you can reuse snippets from other user. Wiki were designed to share any type of content. Some tools have been specifically designed to share code snippets. Some IDEs also have snippet features. A wiki is definitely not the best match because it will not integrate with your IDE requiring you to have a separate tool open.

I'm going back and forth between a few Mac applications (haven't decided on one yet but I have tried quite a few). Most of these options allow you to host your snippet library on Dropbox or another network storage location so you can share your library with others. I don't know of any that provide any sort of live changes monitoring though.

Text Expander

Though not designed as an actual code snippet application, I used this for that purpose for a while and was quite content with it. You can share your library with others whether they're on Mac or Windows because there is a compatible alternative for Windows (i forget the name of the Windows alternative but it's easily found on Google I'm sure)

Finally decided to move on because I just wanted something a bit more robust. But may be an option to consider for some.

Codebox

enter image description here


Dash

I just learned about this one and actually only just started trying it. So far it's pretty good and I haven't decided whether or not I'll stick to this or go back to Codebox. I really like the documentation library functionality it has but as far as storing snippets, with my limited experience thus far, all I can say, is I'm rather disappointed in the codehighlighting. It also doesn't have additional fields to write comments like some of the other applications do so your comments have to actually be written with the code. I can't say that bothers me though, it's actually a good thing.

enter image description here


Snippets

I was using this one for a while and liked it quite a lot but wanted something that I could not only store small snippets in but also full source files like a few self contained javascript libraries. I attempted to store a large javascript file and the program not only couldn't handle it, but it actually corrupted my entire snippet library which I was hosting on Dropbox. Not sure if it was a self contained problem because I immediately uninstalled the app after that. But overlooking that i

enter image description here


A few others I may try but have no opinion about thus far

Code Bank (open-source)

Code Collector Pro


Last but not least.. I've actually just been using Gist more and more lately. I'm not aware of any desktop application for Gist (there's a browser app for Chrome I think and a couple of third party applications on the AppStore but I haven't tried them)

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top