Gherkin editor, syntax highlighting and auto complete to write your stories.

Published on Mar 16, 2010

Last Friday I was showing some of the guys at the office how to write user stories with the Gherkin language to been able to use them in either Cucumber or Specflow as executable specifications.

They were receptive but they have a problem. Notepad. They wanted to use Word and have a template, and some spell checking support….

At first I got a little frustrated but I actually thought about it and try to put myself on their shoes. Here I’m, a developer, asking to the business to write specs in a very specific format. It’s not that they were negative about it, but they were expressing they concerns and they needs.

Enter Gherkin editor.

So I decided to try to create a simple editor with some of the features requested. I remembered some time ago an interview on DNR with a PM for the SharpDevelop team. He mentioned that they had the editor surface as either a service or a plug in. After searching I found it (AvalonEdit) and also a nice little sample app.

So I got the code, read the documents and after a few hours of hacking with the sample I was able to put together a super basic editor.

I hosted the code in Codeplex using Mercurial and just added the first Release 0.1 alpha, work on my machine, use at your own risk, etc, etc.

Some screenshots.

syntax-highlighting

auto-completion

Future plans

The next step will be to add spell checker and a template to create a new document. Contextual code completion could be a nice to have. Multi language support is a must for Cucumber.