microsoft / azure-devops-dotnet-samples

.NET/C# samples for integrating with Azure DevOps Services and Azure DevOps Server
https://docs.microsoft.com/azure/devops/integrate
MIT License
519 stars 511 forks source link

Create PR with autocomplete #284

Open ajuliang opened 4 years ago

ajuliang commented 4 years ago

Hello. I want to create a PR with autocomplete and I sent the following request:

GitPullRequest parameters = new GitPullRequest() { SourceRefName = "branchsource", TargetRefName = "branchtarget", Title = "titulo pr", Description = "desc pr", AutoCompleteSetBy = new IdentityRef { Id = identity.Id.ToString() }, CompletionOptions = new GitPullRequestCompletionOptions { MergeCommitMessage = "Merge: desc pr", DeleteSourceBranch = true, MergeStrategy = GitPullRequestMergeStrategy.Squash, SquashMerge = true } };

_gitClient.CreatePullRequestAsync(parameters, repo.Id).Result;

The PR was created without the autocomplete feature.

How can I fix my code?

Thank you.

qfai commented 4 years ago

I have the same problem. How to create a autocomplete PR?