Streamlining Issue Management with GitHub and YouTrack
October 24th, 2011 by Hadi HaririThe Typical Developer Workflow

* Thanks to @gregyoung for enriching me with whatthecommit.com
In general, as developers we hate uninteresting tasks such as managing issues, so the less time and effort we spend in tracking bugs and features the better. The worse case scenario is the one outlined in the previous workflow, i.e. work on a bug, comment the fix in source control and then separately manage the issue in an issue tracker. Ideally, we’d like to only have to indicate what we’ve worked on and how it’s related to a check-in once! And fortunately with YouTrack, we can. However, YouTrack goes one step further. It actually allows us to control issues from our source control. Let’s see how this plays out when it comes to using GitHub.
In essence we have two options when it comes to integration GitHub:
- Directly via GitHub Service Hooks.
- Use TeamCity as the gateway, which in itself offers other advantages (opening it up to other VCS’s too).
We’ll cover each of these in detail.
YouTrack and GitHub Service Hooks
Earlier this year, GitHub provided official support for YouTrack hooks, allowing for tight integration between the two systems. This makes it extremely easy to set up YouTrack for issue management.
Assuming we have a project already set up on YouTrack and GitHub:
1. Click on the project in GitHub and select Admin
2. Select the Service Hooks from the left-hand side menu

3. At the very bottom of the list of Service Hooks, select YouTrack

4. Enter the following information in the form provided

A few things to note here:
- Base Url is the url of your YouTrack server, which is independent of the actual project.
- Committers is the group in YouTrack that has permission to commit to source code for the particular.
- Username should be a user on YouTrack with Server Admin rights [In an upcoming release this will change to only require Project Admin rights].
5. Switching over to the YouTrack side, the only thing required is the to create the Committers group and add the correct users to it. This step isn’t required but it’s good practice to limit the users that can update an issue to those associated with the project.
6. A last important step (which is performed once only) is to make sure the REST interface is activated on YouTrack (via the Administration Settings)

Putting it to work – Hello YouTrack Commands
Now that we have the two systems linked up, how do we actually get this to work? If you’re not familiar with YouTrack, you might not know about an amazing feature it has called commands.
When most people look at YouTrack, all the see is just another web application with links to click on. However, the true power of YouTrack is in it’s support for commands, which is basically a way of sending it different pieces of text that it understands. This is normally done using the Invoke Command window (Alt+Ctrl+J…yes YouTrack is VERY keyboard friendly):

We start typing text and YouTrack offers us completion and tries to figure out what we’re trying to do. It’s smart enough that it doesn’t need us to spell things out, i.e. instead of having to type “state: fixed assignee: hhariri”, we can just type “fixed hhariri” and it figures out the rest:

It even remembers recent commands we’ve applied to offer the same combinations to us on the next input.
Now if we take this concept of commands and combine that with the usually useless commit messages we can actually come up with something useful! We can use the commit messages to send YouTrack commands (in fact, with YouTrackSharp I’ve started implementing PowerShell commandlets to allow console support for YouTrack too). As such, from our console our Git GUI we can do the following:

What we’ve done here is provide a command as commit message. We’ve identified the issue we’re going to apply the command to (issue Id prefixed with #) and followed it by the command Fixed.
Once we do this and push it to GitHub, the Service Hooks in GitHub will now supply this information to YouTrack, which in turn parses the command and applies it to the issue:

Notice a few things here:
- The issue’s history has been updated with the date/time it was resolved along with a comment saying it was emitted via commit by hhariri.
- The issue has been actually marked as Fixed.
- The Username is clickable. It has correctly identified the username that checked in and mapped that to the YouTrack user. How does it do know that? Simple. It’s based on the email address. That’s why it’s important to have the correct email address associated with both account.
Multiple Issues
YouTrack also supports multiple issues being updated via the commit message. In order to do this via the commit message, each issue should be on it’s own line (i.e. when using the console, don’t provide the –m option with the commit and have Git prompt you with an editor to input comments).
Also it is important to note that the commit messages are not limited to just the “Fixed” command, but other commands can also be added such as tagging an issue, etc. (comments currently is not supported).
Integrating GitHub (or any VCS) with YouTrack via TeamCity
The second option for integration between YouTrack and GitHub is using TeamCity as the gateway. The advantage to this mechanism (apart from using TeamCity!) is that it now opens the door to more VCS options, including Subersion, Perforce, Git, Hg and all VCS’s that TeamCity supports.
The steps to integrate YouTrack and TeamCity are pretty straightforward:
1. Click on YouTrack Administration and select TeamCity Integration

2. Select to Enable TeamCity Integration and click on the Add TeamCity Server link

Enter the information as described in the dialog box and click Save.
3. Once the server is set up, we now need to define the mappings between TeamCity and YouTrack projects. For that, we click on the define mapping link:

We need to define pretty much all the values in the dialog box (which are self-descriptive).
In addition to the minimum required settings, we can also define restrictions on which groups have access to viewing issues via the Permissions tab, as well define a default command to be set on issues affected by failed builds:

4. In order to get the User Mapping, YouTrack like before uses the Email address. As such, we need to make sure that our VCS is configured to map to email. This is done on the TeamCity side under My Settings and Tools which is located under the Username menu [Note we have now switched to TeamCity]:

We edit the corresponding settings and set the Git roots to use email:
![]()
5. That’s all that is needed in order to get VCS commands working via TeamCity acting as gateway. This will now provide us information and output like the following in YouTrack when sending a fixed command via a commit message:

With this, a new Tab appears on YouTrack named TeamCity which contains information about the commit being made along with a link to the username.
We could in essence stop right here. The next step however is to go full force and get some of the added benefits of integrating TeamCity and YouTrack, this time from TeamCity’s side.
6. Under TeamCity Adminsitration click on Server Configuration and then on the Issue Tracker tab
![]()
7. We now need to create a new connection by clicking on Create New Connection, and entering the following information:

Once we test the connection we can click Create and we’re done. From this point on, we can click on Changes and have drill-down information on issues, link directly to them, etc.
Summary
As we can see, there are two ways to integrate YouTrack and TeamCity. The former requires a little bit less of a setup but is restricted to GitHub (currently). The latter gives us the full benefit of having a tight integration between TeamCity and YouTrack and opens up the door to using any VCS that TeamCity supports.
Most importantly however, the purpose of all this is to streamline the process, making issue management simple, non-intrusive and easy to work with.
[Note: If you’re an OSS project lead, note that TeamCity and YouTrack Integration are already setup on Codebetter.com. Ping me if you need help setting up your project details to take advantage of what’s been explained here].
The JetBrains Magical Mouseless Continuous England User Group Tour
October 18th, 2011 by Hadi HaririAfter months of preparations and in collaboration with NxtGen User Groups, VBug and Anteo, we are happy to announce the upcoming JetBrains User group Tour of England: 5 Days, 5 Cities, finishing it off in London in style!
The Tour Dates
- Monday 14th Nov - Essex
- Tuesday 15th Nov - Cambridge
- Wednesday 16th Nov - Manchester
- Thursday 17th Nov - Coventry
- Friday 18th Nov - London
(For more information and Registration, see below)
The Agenda for Essex, Cambridge, Manchester and Coventry
Mouseless Driven Development
Do you know ReSharper, are using it or have used it in the past? Do you think you are getting the full potential out of it? Even developers that have been using it for several years often only scratch the surface. Come and learn all the tips and tricks of ReSharper and see how to use it to it’s full potential to truly create a mouse less driven development environment.
The Agenda for London
The London event will be slightly longer, but will be compensated with Food and Beer!
Mouseless Driven Development
Do you know ReSharper, are using it or have used it in the past? Do you think you are getting the full potential out of it? Even developers that have been using it for several years often only scratch the surface. Come and learn all the tips and tricks of ReSharper and see how to use it to it’s full potential to truly create a mouse less driven development environment.
Continous Delivery
Paul Stack joins us to talk about Continuous Delivery and how to use TeamCity for this purpose:
Sebastian Lambla will show us to to twist Visual Studio and ReSharper to provide dynamic plug-in functionality with OpenWrap.
Registration
If you are going to attend the London meeting, please use our EventBrite page to sign up. If you are going to attend one of the other meetings across England, please use the corresponding link below to register directly with the user group.
- Monday 14th Nov - Essex
- Tuesday 15th Nov - Cambridge
- Wednesday 16th Nov - Manchester
- Thursday 17th Nov - Coventry
- Friday 18th Nov - London
(In London we will be providing Food and Drinks, so please make sure that you sign up ahead of time. Places unfortunately are limited to approximately 70 people!)
Scotland
Unfortunately, despite our initial intentions of also including Scotland in the tour, we were not able to due to scheduling. However, we hopefully do plan to repeat the tour with Scottish User Groups in the New Year so please stay tuned!
Thank you!
A big Thank You to the Coordinators of NxtGen User Group, VBug and Anteo for their efforts in organizing this tour and collaborating with us in all possible ways.



dotCover Console Runner Enhancements
October 18th, 2011 by Hadi HaririI’ve previously blogged about the possibilities of running code coverage using the dotCover console runner. You can find the Simple Coverage post here and the more Advanced post here. In dotcover 1.1.1 we made some changes to the console runner to facilitate the process even more.
Command Line Arguments
Previous versions of dotCover required that you specify the configuration parameters in an XML file. In dotCover 1.1.1, we now give you the possibility of defining these values directly on the command line in addition to XML Files. The way in which it works is similar to that of MSBuild, that is, you can define or override definitions in the XML file by passing them as arguments on the command line. For instance, take the following configuration file:
<CoverageParams>
<TargetExecutable>mspec.exe</TargetExecutable>
<TargetArguments>tests.dll</TargetArguments>
<Output>output.dcvr</Output>
<InheritConsole>true</InheritConsole>
</CoverageParams>
If we want to override the Output , we could run this from the command line by passing in the Output folder argument:
dotCover cover coverage.xml /Output=new_output.dcvr
We can do this with any command (cover, report, merge, analyze, etc.) and with any parameter. Parameter names match one-to-one with the element names specified in the XML. As such, to override the <TargetExecutable> element, we would use /TargetExecutable=…., providing us with the flexibility of having a single configuration file and allowing certain parameters to be overridden when required.
InheritConsole
A new parameter is available in the cover and analyse command which is InheritConsole. What this does is inherit the console output of the target executable. This is useful for instance in passing messages to TeamCity log output (if for some reason you do not want to use the built-in dotCover in TeamCity). By default it is True.
Support for relative paths
One of dotCover’s earlier shortcomings was the inability to provide support for relative paths in configuration files. This has now been solved in version 1.1.1 also, providing the ability to define relative paths, both in the XML as well as command line arguments.
Relative paths defined in the XML are relative to the location of the XML file. Relative paths defined as command line arguments are relative to the location of the console runner working directory.
Coverage Result Descriptors
In earlier versions of the console runner, dotCover would produce what’s called Result Descriptors, which were index of snapshots. These files were normally required in an intermediate step for merging output of different coverage runs (see Advanced Coverage post for more details). This has also changed. Coverage now produces snapshots directly. This allows the generated files to be opened directly in Visual Studio using the Open Coverage Snapshot entry in the dotCover menu.

For backwards compatibility, intermediate index files are still supported, albeit new coverage calls will no longer generate these.
dotCover 1.1.1 is available for download here.
DevelopMentor Partnership
October 11th, 2011 by Hadi HaririWe have some very exciting news to announce!
We have reached an agreement with DevelopMentor, under which they will include ReSharper with all their open enrollment .NET courses in the UK and US. This means that when you enroll in one of their courses, you get a free Personal License of ReSharper Full Edition.

DevelopMentor are specialized in intensive and in-depth .NET Training. With a range of well known instructors such as Richard Blewitt, Andrew Clymer, Michael Kennedy, Anthony Sneed, Jason Whittington, Mark Blomsma among others, you are sure to get .NET training from highly skilled and knowledgeable professionals. And now you can walk away, not only knowing how to make the most out of Visual Studio by leveraging ReSharper, but also keeping your own license!
Here’s a list of DevelopMentor .NET Courses. If you haven’t already checked them out, make sure you do!
BASTA! Prize Winners
October 4th, 2011 by Hadi HaririWe had our first booth at BASTA! Autumn last week and we were very glad to take part in the conference. A lot of great interaction with the audience and a chance to talk to both new and existing users of our products. As those of you that were there know, we raffled out 30 licenses at the conference!
If you’re not one of the lucky winners, you still have one more chance to win. Among all those that filled out the Prize drawing cards, we have selected three winners (who chose their own products):
And the lucky winners are…..
- Raimund Keese - dotTrace [Update: Has already won a license at Raffle on-site]
- Steffen Hamman - dotTrace [New Winner since Raimund was picked already]
- Alexander Polischuk - ReSharper
- Kai Moosburger - ReSharper
Congratulations. Your license will be on it’s way in the next few days!
See you at the next conference (and if you happen to be at FOWA in London, stop by and say Hello!)
dotCover Roadmap, Subscription Renewals, and 1.2 EAP
September 30th, 2011 by Jura GorohovskyOur salute to everyone covering their .NET code!
We have several dotCover-related news items this time: what’s new in dotCover 1.2; how dotCover is going to evolve mid-term, and how to make sure you’re eligible for subsequent dotCover versions.
dotCover 1.2 EAP
First of all, we have recently started Early Access Program for dotCover 1.2. This is a maintenance release that could be of interest to those of you who are using dotCover with massive solutions and experiencing performance and memory issues.
- Improved performance of report generation and coverage highlighting. This doesn’t have anything to do with creating a snapshot but rather with its further processing. We have clocked moderate performance improvements in generating reports for ReSharper solution. We’d be happy to know whether this also gets things smoother for you if you’re using dotCover on large solutions.
- Reduced HTML report size: both in Visual Studio and in the console runner. Specifically, we have managed to reduce the size of ReSharper report 1.5 times, making it 10 Mb lighter.
- Reduced memory consumption during snapshot merge. This is based on internal feedback but may very well make life easier for everyone who has ever encountered OutOfMemory exceptions on merging snapshots.
- Miscellaneous bug fixes and minor improvements: see this YouTrack query for complete release notes.
One more thing about this EAP is that it’s prepared to support ReSharper 6.1 that we’ll hopefully make available for early access in two weeks’ time.
dotCover Subscription Renewal Licenses Available
It’s now been a year since dotCover 1.0 was released, and since a dotCover license includes one year of free upgrades, the free upgrade period has just expired for some dotCover users. If you’re using a recent dotCover version and there’s a “license not acceptable” message in your dotCover License Information dialog box, that means you’re no longer eligible for free upgrades:

If you would like to be able to upgrade to forthcoming versions of dotCover (see below for some of the reasons why you’d love to) for another year, you should purchase a 1-year upgrade subscription renewal license, which is worth (roughly) 50% of the current initial license price — that is, $75 or equivalent for commercial license upgrade subscription renewal, and $39 or equivalent for personal license upgrade subscription renewal.
To renew your upgrade subscription, refer to one of the two e-mail reminders that we’re sending out when a subscription is going to end soon, and as soon as it has ended. If you haven’t received any reminder e-mails, please go to dotCover buy page and use the new “Upgrade subscription renewal” license option in either “Commercial license” or “Personal license” column:
For detailed upgrade subscription terms, please proceed to this page.
dotCover Roadmap
You will hardly want to purchase any upgrade subscriptions without knowing in which directions the product is going to evolve. Here’s a quick roadmap highlighting features that we’re going to make available in new releases during the year ahead:
- Running and measuring coverage of unit tests without ReSharper. Current versions of dotCover rely heavily on ReSharper unit test runner (and its framework-specific plug-ins) for running and measuring coverage of unit tests. You just can’t execute unit test coverage without integrating dotCover into ReSharper. This isn’t a problem for ReSharper users but there’s no way to reach a wider audience until dotCover provides its own test runner — and it will do so! Unit test runner, currently ReSharper’s exclusive asset, will soon be available in both ReSharper and dotCover, making unit test coverage possible without ReSharper’s assistance.
- More built-in navigation. ReSharper provides more than unit test runner to dotCover: certain navigation actions in dotCover are only available if ReSharper is installed in Visual Studio. For example, you can’t currently navigate from Coverage Results Browser to Visual Studio text editor using the keyboard: this is only possible from the Coverage tab in ReSharper’s Unit Test Sessions. Inconveniences like this will also be removed as dotCover gains more intelligence from ReSharper.
- Priority coverage suggestions. We’ll train dotCover to gather metrics such as cyclomatic complexity in order to suggest which parts of your code base should be covered with unit tests in the first place — thus evolving from formal coverage statistics to a more insightful and task-efficient approach.
- Coverage filtering by attributes. dotCover will enable you to create attribute filters. It will skip measuring coverage of code marked with attributes you’re listed. This will help prevent wasting time on measuring coverage of auto-generated code and any other kinds of code that you don’t want dotCover to process. In configuring filters, you’ll be able to use both common attributes like
GeneratedCodeor MSTest’sExcludeFromCodeCoverageAttribute, and any other attributes used on assembly, method, or class level.
This is not all features that we’d like to implement in near future — rather, those that we’re confident in being able to bring to life. On the other hand, we don’t have an ultimate list of expected changes, and as usual, you can throw your suggestions via dotCover issue tracker or discussion forum, and we’ll take your input into account as we schedule our development process.
BASTA!
September 20th, 2011 by Hadi Hariri
JetBrains will be exhibiting at BASTA!, one of the longest running and key .NET conferences in Europe. BASTA! Autumn which is held in the city of Mainz (with the conference venue overlooking the river), will take place from the 26th to the 30th of September.
Stop by our booth and see what we have in store with upcoming versions of our tools! Grab a T-Shirt, have a chat!
Industrial Logic: Your Personal Trainer 24×7
September 12th, 2011 by Hadi HaririTest Driven Development is easy. You write a test, then you write the code. Seems simple enough, yet it normally is not, and when you’re just getting started, you often make mistakes. It doesn’t matter how many times you read the steps or follow a course, as a novice you are still unsure whether you’re doing it right or wrong.
It would be great if somehow, there was someone constantly monitoring you and telling you whether you’re taking the right steps. Whether you are refactoring when you should, whether you are making tests fail before they pass. It would not only help newbies, but also help some of us to be a bit more disciplined. Up to now, this kind of monitoring was really only viable while having an instructor next to you. However, that has changed.
Industrial Logic, founded by Joshua Kerievsky, author of the well-known book on Refactoring to Patterns (highly recommended) have courseware on topics such as design, code smells, refactoring and test driven development. The difference with these courses however is that apart from being interactive and providing exercises, they also monitor how you perform these exercises by using a neat little plug-in for ReSharper that they’ve developed.
How it works
When you sign up for a course that involves exercises, such as their TDD course, you are prompted to install a ReSharper Recording plug-in:
![]()
Once this plug-in is installed, it will then automatically start recording any exercises you do. In the case of the TDD course, these exercises are designed to show you the flow of TDD: Red, Green, Refactor. It gives you a brief description of the required code to write and starts you off with a blank test. The one below for instance is to calculate bonuses:
![]()
Once you complete the exercise, you then upload a file. This file is the recording that the ReSharper plug-in has made. It includes information such as compiler errors, warning, the refactoring steps you’ve made, and a whole bunch of other useful information. Once this file is uploaded, it is analyzed and results are produced for you:
![]()
This graph indicates the portion of time that your code had errors, the amount of time with failing and passing tests as well as the actual phases. Every dot on the graph also provides detailed information about the event, along with a score.
These scores are determined by the activities that take place:
![]()
For instance, here we see that we performed a refactoring while having compilation issues, giving us a score of 0, or performing another refactoring before tests are run, resulting in a –1. These events all add up along with other factors to give you an overall score:
![]()
It doesn’t end there
The great thing about this however is that it doesn’t end with your score. As I mentioned, this course is fully interactive, which means that not only can you interact with instructors, but also other alumni, via in-place forums. For instance, below is a screenshot of a question that is asked after the exercise. It includes not only your response, but the percentage of the overall responses from other students along with open discussions from instructors and alumni:
![]()
This kind of interaction is invaluable. Not only do you have a monitor recording your steps, but you can also discuss issues you encounter or doubts you have throughout the course. What is also great is that all the mentors and instructors of Industrial Logic make it clear that there is no absolute truth. Every response, every comment, is always with the utmost respect and given from a personal experience perspective.
Watch it in action
The folks at Industrial Logic have put together a small video which shows how this works in action:
Beyond Exercises
This recorder is great for exercises and learning, but it doesn’t stop there. When signing up to their courseware, you are also provided the option to have the ability to record steps on live projects and have them analyzed (Sessions album). Think of the scenarios this could help with! Not only can you see for yourself if you are doing things in ways that can be improved, but it also allows you to teach and help junior developers on your team.
The TDD course as well as many of the other courses surrounding refactoring and code smells by Industrial Logic are of the highest quality. They have an extensive album (as they call it) of courses.
Special ReSharper 6.0 Recorder Launch offer
To celebrate the release of Industrial Logic’s Recorder for Resharper 6.0, they are offering a 30% discount on the purchase of one of the following albums:
To obtain this special offer, please use the following discount code when ordering your album: ILRECORDER60. Please note that this code is valid until the 30th of September, 2011.
JetBrains at // BUILD
September 9th, 2011 by Hadi Hariri
JetBrains will be exhibiting at Microsoft’s upcoming // BUILD conference. Like everyone else attending, we’re also eagerly awaiting to see what Microsoft has in store for us.
We will also be showing some new things at our booth and support for the latest technologies, both for Web Development as well as Rich client development such as XAML. So make sure to stop by, say hello and pick up a T-Shirt (Yep, we’ll also have Dead Code ones).
See you there!
Update: Sorry guys, no t-shirts this time. Logistics failure. Still, you’re pretty much welcome to the booth for a chat with Hadi, Brian, and Slava: the guy who owns the live template subsystem in ReSharper.


