10

Quick Question for Visual Studio 2019 Version 16.8.3, How do you connect the work item to the commit in the new git changes tab? I am having a really hard time using this new git experience thing. I can see my work item in team explorer but no idea how to add this work item to the commit in this new interface. Usually, there will be a button to add related work items when committing the files in the previous version. Please someone help me out?

phonemyatt
  • 1,287
  • 17
  • 35
  • 1
    it look like you can just use hashtag '#' in commit message, but the work items is commit message. I don't want work item in my commit message – phonemyatt Dec 11 '20 at 01:10

3 Answers3

12

it look like you can just use hashtag '#' in commit message,

That is the recommended syntax.
Example:

Fix a bug #1234

That would actually close the work item

See more at "Drive Git development from a work item" You can link a work item to commits but also other objects:

The link types you can add within the development section are Branch, Build, Changeset, Commit, Found in build, Integrated in build, Pull Request, and Versioned Item.

https://learn.microsoft.com/de-de/azure/devops/boards/queries/media/link-tracking-artifact-to-artifact-link-types.png?view=azure-devops

VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
2

Looks like the option to turn off the awful "new git experience" is gone from VS2022. And there is still no option to add a DevOps work item like you could in the Team Explorer.

Another example of M$oft not listening to their users.

ficelles
  • 429
  • 1
  • 4
  • 7
0

You could also turn of the preview of the new Git features. TOOLS=> OPTIONS => search for preview => checkbox

settings

If you like the preview feel free to keep using it of course. Personally I'm not really digging it.

MSblogPostAndReasons

  • I already tried that, it seems like microsoft plans to go with this changes and every visual studio update will change the setting back to this new git feature – phonemyatt Dec 14 '20 at 01:49
  • Yea but at least I'm seeing a lot of feedback on their post. Let's hope it get's improved for the better in the future. – Bert Huysmans Dec 15 '20 at 10:15