YouTrack Server 2024.3 Help

Add Comments

Comments are a great way to add detail to an issue or ask questions for clarification. You can add comments to an issue after it has been reported. You cannot add comments to an issue draft. You and other users can add comments to reply to a question or provide additional information that helps to resolve the issue.

Add a Comment in the Issues List

If you're working with a list of issues and see one where you would like to post a comment, you can open the issue in quick view and add your comment without leaving the list.

The option to switch the quick view on and off is available from the List Settings menu in the table header.

To add a comment from the Issues list:

  1. Once you open the issue, scroll down to the input field and enter your comment. You can format your comment text in Visual or Markdown mode.

    Adding a comment from the Issues list in YouTrack Lite.
  2. To attach a file with your comment, click the Attach files icon in the toolbar. When the comment is added, the attachment is displayed inline with the comment.

  3. To restrict the visibility of the comment, select a group from the Visible to menu. For more information, see Visibility for Comments.

  4. When done, click the Add comment button. You can also perform this action by pressing Ctrl + Enter on the keyboard.

    To post the comment and update the status of the issue, expand the menu next to the Add comment button and select a target state from the list.

If an issue already has one or more comments, you can add a comment to an issue directly from the Issues list. Otherwise, open the issue in single issue view and add your comment there.

To add a comment from the Issues list:

  1. Click the comment icon. The number next to the icon displays the number of comments that have already been added to the issue.

    Adding comments from the Issues list.
    • If comments are already added, the selected issue expands to display the most recent set of comments and the input field for adding a new comment.

    • If the issue doesn't have any comments, you can still add a comment directly from the Issues list. Just press the keyboard shortcut Right Arrow twice. Once to expand the selected issue and a second time to display the input field for adding a new comment.

  2. Enter your comment in the input field. You can format your comment text in Visual or Markdown mode.

  3. To restrict the visibility of the comment, select a group from the Visible to drop-down list. For more information, see Visibility for Comments.

  4. To attach a file with your comment, click the Attach files icon in the toolbar. When the comment is added, the attachment is displayed inline with the comment.

    Controls for adding comments in the Issues list.
  5. When done, click the Add comment button. You can also perform this action by pressing Ctrl + Enter on the keyboard.

Add a Comment to Multiple Issues

You can add the same comment to several issues simultaneously with a command. Use this feature when there is a batch of issues that you want to update with the same comment.

To add a comment to multiple issues:

  1. Select the issue that you want to update in the Issues list.

  2. Click the Add comment button in the toolbar.

    • The Apply Command dialog opens. The comment command is already specified.

      Adding a comment to multiple issues with a command.

    Alternatively, you can just type any letter or press Ctrl + Alt + J to open the Apply Command dialog. In this case, the Command input field is empty.

  3. Enter your comment in the input field.

  4. To restrict the visibility of the comment, select a group from the Visible for Group drop-down list. For more information, see Visibility for Comments.

  5. When done, click the Apply button. You can also press Ctrl + Enter on the keyboard.

    • The commands are applied and the comment is added to all the selected issues.

    • Any commands that apply updates to the issue are shown alongside the comment. For more information, read the Comment-related Updates section below.

Add a Comment in Single Issue View

Adding a comment in single issue view is as easy as it gets: just enter your comment and click the Add comment button.

To add a comment to an issue:

  1. Open the issue where you want to add a comment.

  2. Enter your comment in the input field. You can format your comment text in Visual or Markdown mode.

  3. To restrict the visibility of the comment, select one or more users or groups from the Visible to list. For more information, see Visibility for Comments.

  4. To attach a file with your comment, click the Attach files icon in the toolbar. When the comment is added, the attachment is displayed inline with the comment.

    Add comment single issue view
  5. When done, click the Add comment button. You can also press Ctrl + Enter on the keyboard.

    To post the comment and update the status of the issue, expand the menu next to the Add comment button and select a target state from the list.

    Add comment single issue view

Generate Comments from VCS Commits

When you work with issues in a project that has been integrated with a version control system, you have the ability to generate comments when you commit changes to the repository. This feature is supported by the following integrations:

The settings for your VCS or build server integration include an option to parse commits for issue comments.

  • With the Parse commits for issue comments option enabled, commit message text that starts a new line after a command is copied to a separate issue comment. This behavior lets you mention users in comment text and generate notifications when the commit message is processed.

    It also lets you choose to make commit-related information visible to external users who don't have permission to view VCS changes.

    commit message with user mention
  • With this option disabled, issue comments are not generated from commit messages. This behavior ensures that additional messages that are generated by the IDE or VCS are shown together with the VCS change and do not generate redundant comments. For example, messages that indicate changes that were cherry-picked from specific commits in other branches of the repository. If the Parse commits for issue comments option is enabled in the project, these auto-generated messages generate separate comments.

    commit message with cherry pick

This feature can be enabled or disabled independently on a per-project basis. It's up to project administrators to determine which behavior is most desirable for issues in their projects.

If the feature is enabled, you can use the following syntax to generate a comment from a VCS commit message:

[commit message text] #issueID [command 1] [command 2] ... [command n] [issue comment text] ...

or

[commit message text] ^issueID [command 1] [command 2] ... [command n] [issue comment text] ...

The entire commit message, including commands and issue comments, is always shown as part of the VCS change record in the activity stream.

commit message with command

The commit message is broken down into the following components:

Component

Description

Commit message text

The first string of characters is added to the VCS commit message. This text is not applied as a comment to the issue. The complete VCS commit message is displayed in the list of VCS changes in the activity stream.

The commit message text can wrap multiple lines and include empty lines.

Commands

YouTrack recognizes the number sign (#) or caret (^) as a flag for an issue that is followed by a command. The characters that follow the number sign or caret are parsed to match an issue ID. Any string that follows the issue ID is parsed as a command up to the end of the current line.

For more information, see Apply Commands in VCS Commits.

Issue comment text

If the Parse commits for issue comments option is enabled for your integration, text that is added as a new line after a command is copied from the VCS commit message and posted to the issue as a comment. Otherwise, the text is only shown in the VCS commit message.

Issue IDs

Any issue ID that is found in the commit message is transformed into a hyperlink. This includes issues that are flagged for a command and issues that are simply mentioned in the commit message or issue comment text.

Attach Files to Comments

When you add a comment to an issue, you have the ability to attach files directly to the comment itself. Files that are attached to comments are shown in the Attachments section of the issue and are also displayed as thumbnails directly under the comment text.

Settings in the Attachment options allow you to separate attachments for the issue and the attachments in the comments.

Attach files to comments

The option to attach files to comments is available on the Issues list, when viewing single issues, and when you open a card in view mode on an agile board. You cannot attach files when you add a comment with a command.

By attaching files to comments instead of merely attaching the file to the issue, teams who work with versioned files can quickly locate the most recently updated copy.

To attach files to a comment:

  • Click the Attach files icon in the toolbar for a new comment and select one or more files from your local directory. Click the Add comment button to add the comment and attach the files.

    The comment text is optional.

  • To add a file to an existing comment, click the Edit comment icon, then attach the files using the Attach files icon in the comment toolbar.

  • Drag files to the target comment or the input field for a new comment, then click the Add comment button.

For each file attached to a comment, you have access to the same actions that are available in the Attachments section of the page.

Attachment options comments
  • For files with visibility restrictions, move the pointer over the padlock icon to display the list of users and groups who can view the file.

  • Click the thumbnail to preview images or download other file types.

  • Click the View text icon to view, select, and copy the text recognized in the image. For more information, see Text Recognition.

  • Click the Download icon to copy the file to your local directory.

  • Click the Edit icon to update the file.

    • Images open in the image editor. Here, you can apply changes directly to the image, change the filename, and update the visibility settings for the file. For more information, see Edit Images.

    • For other files, this action opens the Edit Attachment dialog. Here, you can change the filename and update the visibility settings. For more information, see Edit or Remove an Attachment.

    Any change applied to a file that is attached to a comment is replicated in the copy of the file that is shown in the Attachments section of the page.

  • Click the View file details icon to view the file name, size, upload user, and upload date.

  • Click the Remove attachment icon to remove the file from the comment. When you confirm this action, the reference to the file is also removed from the Attachments section of the page.

Pinned Comments

You can give important comments extra visibility by pinning them to the top of the comments section in the activity stream.

To pin a comment:

  1. Locate the comment that you want to pin in the comments section of the issue.

  2. Open the More actions menu in the comment toolbar.

  3. Select the Pin comment option.

To unpin a comment:

  1. Locate the comment that you want to unpin in the comments section of the issue.

  2. Click the Unpin comment icon.

Each issue comment has a toolbar. Use the controls in this toolbar to perform actions that are specific to the selected comment.

Comment toolbar

The following controls are available:

Control

Description

Add reaction

Opens a menu that lets you post an emoji reaction to the comment. To learn more about this feature, see Use Emoji Reactions.

Reply

Inserts the username of the author for the selected comment into the input field for a new comment. This option is only available for comments that were added by other users. Use this option to reply directly to the user who entered the original comment. For more information, see Mention Other Users.

Edit comment

Opens the selected comment for editing. Depending on your permissions, you can update the comment text or change the visibility setting for the comment.

AI Assistant

Lets you access the options to generate a response to the comment with the help of the AI Assistant.

To learn more, see Assistance With Replies to Comments.

Copy link

Copies a direct hyperlink to the issue comment to the clipboard. This option is located in the More actions menu.

Pin comment

Pins or unpins the comment to the top of the comments section. This option is located in the More actions menu.

To learn more, see Pinned Comments.

View comment history

Opens the version history for the current comment.

To learn more about this feature, see View and Restore Previous Comment Versions.

Delete comment

Removes the selected comment from the issue. This option is located in the More actions menu.

To learn more, see Deleting Comments.

All the changes that are applied to an issue within one minute from adding a comment are considered to be related to the comment. When the issue history is enabled in the activity stream, these changes are displayed immediately following the comment.

Issue comment related changes

Deleting Comments

If — for whatever reason — you decide that a comment is no longer needed, you can delete it from an issue.

To delete a comment:

  1. Locate the comment that you want to delete in the activity stream of the issue.

  2. Open the More actions menu in the comment toolbar.

  3. Select the Delete comment option.

In an effort to preserve the fact that information has been removed from the issue, the deleted comment is replaced with a placeholder that indicates the comment was deleted.

The placeholder for a deleted comment.

This placeholder supports the following actions:

Action

Description

Restore

Reverts the Delete action and restores the comment in the issue.

Delete permanently

Permanently removes the comment from the database. This removes the placeholder for the deleted comment as well.

This option is only available to users who have been granted the Delete Not Own and Permanent Comment Delete permission. This is a special permission that lets users permanently delete comments that were posted by both themselves and other users. By default, it is only available to users who are granted the System Admin or Project Admin role.

Last modified: 06 June 2024