Optimizing project management with Github-Youtrack integration

Sneha Bhattaram

Businesses are stepping ahead faster with the iterative agile framework. Agility helps in optimizing resources and results in faster time to market, higher productivity, better quality, and lower risk. As agile development and testing are performed separately in agile methodology, identifying issues across each sprint and tracking them to resolve becomes tedious. An issue tracking tool with all the necessary integrating options, supports agile SDLC and improves sustainable development.

The Youtrack project management tool adapts easily to the business processes and tracks tasks, identifies bugs, plans sprints, and creates workflows. YouTrack allows the connection to a version control system (VCS) and supports direct integration with multiple repositories, such as GitHub, GitLab and Bitbucket. Unlike other issue trackers, Youtrack can be customised to be agile, monitor the development progress, bring IDE-style intelligence, and import projects, users, and issues from Jira, and other trackers.

Benefits of GIT-Youtrack integration

  • Code changes (QA Automation changes /Dev changes) are tracked according to story/task.
  • QA can readily identify the testing scope through the dev code changes, which will be in the activity stream of that issue.
  • With the automatic update option of issue fields with a single commit, avoid manual overhead of marking the corresponding fields of each story.

To accelerate project management in Youtrack, do the following:

  • Integrate Git Repository to Youtrack
  • Apply Commands in Git Commits

The detailed step by step instructions are given below.

Integrate Git Repository to Youtrack

  • Navigate to Settings -> VCS Integrations
  • Click New VCS Integration and provide the following details in the pop-up:
    • Select the Youtrack project that needs to be integrated
    • Select the Server Type as GitHub
  • By default, the Server Type should be GitHub. Type the following information and click save
    • Type the repository URL. for example,
    • Click Generate token, it will redirect to the to Git URL.
    • Type the required description for token generation and define the required scope for the Personal Access Token. Click Update Token.

    Note: Token needs to be generated from the account who has the owner or Admin permissions for that repository. Also, this token expires only when the user revokes it.

    • Read Scope of the Personal Access Token
    • Copy the token and type the personal access token field. Click Save.
  • When the repository is saved, customize the configurations for the following fields:
    • Monitored Branches: If left blank, it will monitor all the branches in the repository and to monitor specific branches, the branch name can be specified in a specific format as per the text below the box.
    • VCS changes Visibility: Select team names for whom the commits should be seen in the activity stream of the Issue.
    • Parse commits for issue comments: By enabling this, the text that is added as a new line after a command is copied as a comment to the issue. With this, notifications can be sent in the form of a comment to others, who do not have access to the VCS visibility changes.

Apply Commands in Git Commits

When the integration is done, perform the following steps as per the defined role.

  • Person who commits the code:
    While committing the final code, you should execute the following command:
    git commit -m “[commit message text] #youtrackID” status
    For example git commit -m “R page changes #TP-2” Fixed
  • Reviewer who merges the PR:
    While merging, you should provide a message that includes the user story number as a command. The format of the commit message and command description is:
    [commit message text] #youtrackID [command 1] [command 2] … [command n]
    [issue comment text] …

    You can also give caret (^) instead of # symbol
Component Description
Commit message text This is a text message which precedes the commands and is pasted in the VCS record, along with the commit link. It can be of multiple lines as well.
Characters followed by the (#) / (^) symbol is parsed as a Youtrack issue ID. The strings following the ID will be parsed as command to that ID. If the commands exceed the current line it will be truncated; hence to apply more commands, you need to provide them in a new line by preceding it with # or ^ symbol.
If any incorrect command is passed, the command will not be applied and highlighted in red on the VC tab. The tool tip displays the Unsupported command error message.
Issue comment text
When the Parse commits for issue comments option is enabled, text that is added as a new line after a command is copied as a comment to the issue. You can add multiple lines of text between commands.
If this option is disabled in your project, the text is only seen in the VCS record.

You can also apply commands to multiple issues by grouping issue ID’s in parentheses:

[commit message text] (#TP-1, #TP-2, #TP-3) Fixed Tag to be tested

Points to be noted

  • In the commit message, if just the YoutrackID is mentioned without the # symbol, that Commit will still be seen in the VCS record of activity stream as it has the youtrackID. But, the text after the youtrack ID will be considered as a commit message text and not a command.

    For example, commit the PR will display the text Update Text file TP-2 Fixed. The fixed is considered as a text and not the command to the story. Hence, the story will not be updated to the fixed state.

  • All the commits with that PR that has the youtrackID, mention TP-2 will also be seen in the stream. To avoid the number of commit hashes in the stream, do not add ID number in your local commits.

Git-Youtrack advantage

Youtrack and Git Integration will feature:

  • All the commits in GitHub changes links on the VCS changes tab in the activity stream of an issue.
  • Option to apply Youtrack commands directly from Git commit comments/description. For example: moving the state field to Fixed as shown in the below image.
  • Functionality to add commit ID manually using Add Commit link, as shown in the below image.
    With this approach, you will also have the advantage of integrating one GitHub Repository to multiple Youtrack projects or integrate multiple repositories to a single project.


Your email address will not be published. Required fields are marked *