Search code examples
azure-devopsazure-cliazure-repos

az repos pr create multiple reviewers


How can I create a pull request with multiple reviewers from he command line?

The following works:

az repos pr  create -s release -t master --auto-complete --reviewers "mycolleague@company.com"

But as soon as I specify multiple colleagues it refuses to create a pr

   az repos pr  create -s release -t master --auto-complete --reviewers "mycolleague@company.com anothercolleague@company.com"
   Could not resolve identity: mycolleague@company.com anothercolleague@company.com

If I understand the docs correctly, the ids should be space separated


Solution

  • Don't add the " around the list. Quote each identity if needed, but not in a single big string.

    az repos pr create -s release -t master --auto-complete --reviewers mycolleague@company.com anothercolleague@company.com