Disclaimer

The views expressed on this weblog are mine alone and do not necessarily reflect the views of my employer, Avanade.

Search
Recomends...
  • Code Complete, Second Edition
    Code Complete, Second Edition
    by Steve McConnell
Login

Try Snip-It Pro 2.0 Free

Sni-It Pro is a code snippet manager with features designed to make you more productive. Version 2.0 has just been released and includes a ton of new features including support for code teplates, automatic commenting, snipplr integration and more. Try it Today!
> Learn More
Saturday
04Jul

One Day Sale on Bits Du Jour

One week from today, on Saturday, July 11th, 2009 Snip-It Pro will be featured on Bits Du Jour, a daily software deal site.

On this day, and only for this day, Snip-It Pro will be over half off: only $19.95.

Check out the preview page:
http://www.bitsdujour.com/software/snip-it-pro/

If anyone is evaluating Snip-It Pro and needs an extension key to get them until then, send an email to info@snipitpro.com and I'll accomodate you.

 

Sunday
21Jun

Minor Updates

Just released a minor update to Snip-It Pro based on some user feedback.

I added settings to specify a proxy for Snipplr. This will let those corporate users behind firewalls access the Snipplr features from Snip-It Pro.

The other feature I added was a global hot key to toggle the dockable toolbar. Now when you press "CTRL" "Windows Key" "S", the Snippet toolbar will toggle on and off.

If you have any suggestions for Snip-It Pro, send an email to info@snipitpro.com or leave a comment.

Sunday
14Jun

Planning "Architecty" - A tool for creating architecure diagrams

In my last post, I detailed several ideas for new side projects and decided to move forward creating a tool using Silverlight to create architecture diagrams. I spent the majority of this weekend thinking through this idea and configuring my machine to develop Silverlight applications.

For now, I have come up with a working title for the project: "Architecty," and was able to secure "Architecty.com" to house the project. The basic concept is simple. Architecty will be used to easily create conceputal and logical solutions architecture diagrams like this one (taken from patterns and practices archiecture guide):

It is a pain to create these types of documents using Visio. The process usually starts with copying shapes from an existing diagram, playing with the alignment, size and colors inside visio to get things looking how you want. It is a very tedious process and is not really represenative of the architectural relationship you are trying to represent. Also, any changes are very painful because they force you to realign and resize things over and over again.

Sometimes you need create logical architecture diagrams at first, and then once platform decisions have been made you need to create physical architecture diagrams. The basic layout is the same with a few diferences, but you end up needing to do double the work.

The tool I am looking to create will allow you to define a model of the application: the tiers, layers and components that describe the architecture you are looking to build in a tree like user interface. I'll give users templates that define basic types of applications to help speed up this process.

Then when the user is ready, the tool will automatically create the architecture diagram based on the data provided. Boxes will be sized and aligned properly. Once the diagram is shown, you can choose from different color palletes, as well as styles (rounded corners, shadows, etc). At any time you can go back to the definition and change properties that will automatically be reflected in the generated diagram. (I will probably use a tabbed layout for this.)

If needed you can break the tie between the diagram and the model and drag and drop elements the way you would using Visio. This will be to allow for any finishing touches. When you are satisified with the look, you would then be able to push a button and an image will be made available for download.

My current thinking for monetization is that the basic Silverlight application will be free to use. The images it creates will be watermarked. A subscription model will exist to use the tool and generate images without watermarks. When Silverlight 3.0 comes out, we'll leverage the out of browser experience to allow subscribers to use the application offline, though they won't be able to generate images until they are back online (that component will be server based so that it can check if the user is a subscriber).

First I will look to support solution architecture diagrams, in the future I would also want to support infrastructure archiecture diagrams, but that will proabably be down the road.

As I don't have any .Net hosting currently, but I am currently thinking of using the beta Azure platform until I have the application developed. I already have beta access, and have been looking for a project to use it for so this works out well.  

None of this is built yet, and I have to deal with some learning curve for Silverlight. Though I have used it for a toy project, it is nowhere near as complex as this will be.

 

Sunday
07Jun

What's Next? An "Idea Rant" (Yeah, I parked IdeaRant.com too)

Snip-It Pro 2.0 has been released for a few weeks now and I am already looking for a new "side project" to work on. Although I have a few ideas for improvements to Snip-It Pro (Adding Back/Next Buttons to the Snippet Explorer, Supporting Drag Drop from the Explorer window), I am going to put a hold on them to see if the improvements I made so far result in more sales.

Anyway, I have a plethora of ideas for utilities and applications that I have had on hold, many of which I have parked domains for. One of them is to fork the Snip-It Pro code base and create a similar tool for saving other types of copy and cut items such as rich text, images, files and other things that more traditional non technical users would like to manage libraries of. I already snagged a domain for this one: "SideShelf.com"

After spending so much time refactoring, I think I need a break from the code base, so although I will eventually tackle this one, I want to work on a different project in the short term.

I've been sitting on ideas for a couple of ideas for SharePoint extensions, but they would probably make better articles or blog post than full blown products. One is to create a web based utility for editing appsettings and connection strings that is accessed from "SharePoint Central Administration." I've wanted to build this since I first encountered the painful SPWebConfigModification.

The other tool, which I probably need to think through a bit more, is another set of admin pages, and probably some framework libraries, to supplement SharePoint Timer Jobs. I always loved the idea of them, but thought the admin pages for them sucked. Unless I get staffed on another SharePoint project, or have a lot of free time on my hands (not likely), I can't foresee implementing these any time soon.

Other ideas that have been floating around my head include creating a couple of utilities. One, that was particularly interesting is to create a utility that adds buttons to the title bar of every window next to the minimize/maximize window that allows you to turn that window into a dockable application desktop toolbar. I'm not 100% sure it can be done, but if it could, it would be a tool I'd love to use. I frequently want to view two windows at once, and a quick button that could dock them would come in handy.

Another idea for a utility was to create a tool that could start multiple applications at once. I frequently need to open multiple applications to perform a particular task, and thought creating a simple app that would create a shortcut for opening multiple apps would be useful. I also thought it could have another feature that would remember all the running application before a shut down occurred and restart them when the system came up.

Another idea I have is to create a research tool for tracking searches. I find myself searching for the same things from time to time, and also as I search, I end up clicking links from the results to other sites. It's hard to figure out how I got to a particular site days, weeks and months later. So the idea is to create a tool to help track where you go when you search. Maybe implemented as a browser toolbar that sends information to a web service. Then you can log on to a site and view your past searches, and sites you have flagged during those searches. I've got two domains for this idea: "OnceFound.com" and "SearchCrumbs.com".

This is probably the best idea of the bunch, but in the short term I need a diversion, a new, exciting technology to work on.

Silverlight is that technology. I haven't really played with Silverlight since it was in beta (and was called Silverlight 1.1). Back then the tooling support sucked, it had very few controls but I still managed to put together an entry for an internal Silverlight contest that Avanade had hosted internally. I didn't win, but that coupled with a simple WPF app I created for another internal tool has given me an appreciation for Xaml if anything.

So, with the platform a bit more mature, 3.0 in beta with support for an "Out of Browser Experience," my next side project needs to be a Silverlight one. I intend to use Patterns and Practices PRISM, composite guidance for WPF and Silverlight. Having built a few applications with CAB and SCSF, I definitely want to leverage a composite architecture, and after watching some of the quick start demo videos, I definitely think this is the way to go.

As far as ideas for a Silverlight app go, I have two. One is to create a screen mock up app, a la Balsamiq Mockups. I thought it was interesting, but time consuming and not that original. The other idea, and the one that I plan on starting next weekend is for a Architecture Diagramming Tool. Having just rolled off a project, I find myself doing business development work, responding to RFP's, creating slide deck and similar activities. I find myself creating high level architecture diagrams that are pretty similar, but customized to the particular application we are proposing. Normally I do this in Visio, and I think I've gotten quite good at it. But my general idea is to build a Silverlight based tool for quickly creating Physical and Logical Application and Infrastructure Architecture diagrams.

These are actually just some of the better ideas that I am sitting on. I enjoy consulting full time, but sometimes I wish I had the money saved to pursue some of these full time. If anyone feels strongly about any of these ideas, or wishes to collobarate on any of them with me, leave a comment on this post, or click here to contact me.

Wednesday
27May

Why you need a Snippet Management Tool

Early in my career, I was introduced to the concept of snippets in a product for editing HTML called HomeSite, which was then owned by Allaire. I worked on a small team, and we had a bunch of HTML and JavaScript snippets out on a shared drive that we all used. This was in late 1999 right in the middle of the browser wars when an extra line break between your close tr tag and close table tag would wreak all sorts of havoc in how things were rendered in Netscape 4.0 or I.E. 5.0.

I felt there was a lot of benefit out of having this “snippet” functionality. Besides saving time typing, or manually cutting and pasting from one document to the next, everyone on the team used the same snippets and the markup of the pages we created was consistent. This came in handy as were converting a bunch of static html files to proper XHTML compliant format that was inserted into an XML content management system called Dynabase.

After I left that team, HomeSite was bought out my Macromedia and eventually phased out by Macromedia who had similar functionality in their Dreamweaver product, but at the point, I was no longer just an HTML code monkey. I made the transition to classic asp and vbscript and then eventually to .Net and ASP.Net.

Perceived Anti Patterns

For many years I didn’t use a snippet tool. Part of it was the support for snippets in tools like Visual Studio weren’t that good. The other part was that snippets just weren’t cool. You see, copy paste Programmers have given code snippets a bad name. A lot of developers I speak with tend to associate code snippets with inexperienced programmers or hackers, who copy some code off the web without really understanding what it does.

Ask those same developers what do they do when they are stuck on a coding problem, trying to get past some obtuse error message and they say “Google it.” And what do they do when they find a solution: Copy and Paste. Of course it’s not the act of copy and pasting that is the anti pattern, it’s trying to use code that you don’t fully understand.

Real Anti Patterns

But there was a real anti pattern that I found myself falling into with taking this approach time and time again. I found myself googling for solutions to the same problem over and over again. I can’t remember how many times I googled “C# serialize deserialize.” Or “Regex tutorial.”

More troubling were the times that instead of trying to enter keywords that seemed relevant to the issue, I found myself guessing the keywords I used the last time I was looking for something.

I also found myself doing similar things with my rss reader. I found myself sifting through old blog posts looking for a post that I remember addressing something I was trying to do. With Microsoft Outlook, it was usually SQL queries. I would try to remember who I sent one to and try to figure out when, filter by attachments to find a query I sent someone.

This was an information management problem that has wasted a ton of man hours. I know some developers who use OneNote, or all sorts of creative ways of organizing bits of code in text files. Some even use the built in support for snippets in the products they use not realizing there are other solutions.

A Snippet Solution

I created a product to address this need correctly. It’s called Snip-It Pro. And I want you to try it.

I made Snip-It Pro to work the way I wanted. I didn’t want a stand-alone application for managing snippets. The last thing I wanted to do is have to “ALT Tab” all day to get what I needed out of the program.

So Snip-It Pro is implemented as an application desktop toolbar so it can dock to the side of the screen. It is basically a plug in to all the tools you already have. As long as you can drag drop text into your IDE or editor, you can use Snip-It Pro. (You also drag code into snip-it pro to create snippets)

As a professional developer and consultant, I work with multiple languages in multiple environments. My primary IDE is Visual Studio.Net, but I spend a lot of time in SQL Server Management Studio, Expression Studio (for Xaml Silverlight editing), Textpad, Notepad, All parts of Microsoft Office, and other tools like Dreamweaver on occasion. Having all my personal bits of code available to drag drop into any of these application is really nice. The built in syntax highlighting for most popular languages helps too.

Lessons from HomeSite

The other lesson I learned from HomeSite is the power of being able to share snippets, so I implemented snippets as plain old xml files that could be placed on any folder or network share. So if a team wanted to use the same snippets, they just pointed to the same network share.

This capability is even more useful now than it was back in 2000. Like a lot of developers, these days I’m working in multiple environments. Between using virtual machines for development environments to using Remote Desktop or VNC to connect to remote machines, which themselves may be virtualized, it helps to be able to access the same snippets from multiple locations.

One feature I implemented that even HomeSite didn’t have is support for templated code snippets. You can simply add placeholders to your snippets by surrounding text with double square brackets, and the configure snippet bar will automatically display textboxes for those fields when you have a snippet selected. You can then fill out the values and then drag the snippet to where you want to use it and it will automatically have the values merged right in.

Inspired Features

When Jeff Atwood lamented about the ability to trace where a code snippet came from in his post “A modest proposal for the Copy Paste School of code reuse”  on his Coding Horror blog, I implemented a feature that will automatically add comments above a snippet with a unique ID and reference url of a snippet. This, coupled with Snip-It Pro’s ability to track the url of where a snippet came from when you copy it from the web, make it the perfect tool to save code you find online to.

Similarly, when I came across Snipplr, an online community dedicated to sharing code snippets (there are already over 18,000 snippets there) and discovered it had an API, I integrated it into Snip-It Pro so you can view all your favorite snippets and publish your own.

There is a nice video demo of Snip-It Pro on the Snip-It Pro home page. Take a look and give it a try. It’s a free fully functioning 30 day demo and I’m selling it for $39.95, but if you write a review of it on a blog or website, I’ll give you a free copy. Any feedback or feature ideas would be appreciated too.