Skip to content
This repository has been archived by the owner on Jul 12, 2022. It is now read-only.

Option to link to a work item for PRs in azure devops #1115

Open
1 of 7 tasks
yufeih opened this issue Aug 25, 2021 · 5 comments
Open
1 of 7 tasks

Option to link to a work item for PRs in azure devops #1115

yufeih opened this issue Aug 25, 2021 · 5 comments
Labels

Comments

@yufeih
Copy link

yufeih commented Aug 25, 2021

🚀 Feature Requests

PRs in our azure devops repos must be linked to a work item. Today we manually link each PR. It would be very helpful if there is an option to set the work item ID and auto completion for PRs opened by nukeeper.

Platforms affected (mark all that apply)

  • 🛠️ NuKeeper CLI
  • ✨ GitHub
  • 🤖 AzureDevops
  • 🏁 Bitbucket
  • 🌎 Gitlab
  • 📺 Gitea
  • 🐳 Docker
@yufeih yufeih changed the title Option to link to a work item and set auto completion for PRs in azure devops Option to link to a work item for PRs in azure devops Aug 25, 2021
@zplan
Copy link

zplan commented Sep 3, 2021

We would need this feature as well! +1

But I am not sure what the health state of nukeeper is.... is there still someone contributing?

@msallin
Copy link
Member

msallin commented Sep 20, 2021

Since I'm only using Bitbucket and GitHub, I need a few clarifications.

How can a work item be linked in AzureDevOps. Is it enough to have it in the commit message (like for Bitbucket) or is it an explicit action?

How is "auto completion for PRs opened by nukeeper" related to the work item? Is this another feature request?

@zplan
Copy link

zplan commented Sep 21, 2021

Hi @msallin
I did it on my fork of nukeeper:
https://github.com/zplan/NuKeeper/commit/b5eb08e37945821c0a9456728e0f30f988ea9b40

Some notes:

  • It is implemented similar to Labels and it is working but there may be better ways to create the projectUrl in AzureDevopsPlatform.cs.
  • I have just updated compiling issues in the test projects
  • Having the workitem list on the interface leads to a lot of unused parameters for all other platforms (but that is also with labels already)

@zplan
Copy link

zplan commented Sep 22, 2021

I also looked into the "auto complete" topic and it looks like that it is already implemented

[Option(CommandOptionType.NoValue, ShortName = "", LongName = "setautomerge",
Description = "Set automatically auto merge for created pull request. Works only for Azure Devops. Defaults to false.")]
public bool? SetAutoMerge { get; set; }

I was also not aware of that but with the argument --setautomerge it should do an autocomplete.

Because in AzureDevopsPlatform.cs it checks for AutoMerge and sets the AutoComplete:

if (request.SetAutoMerge)
{
	await _client.SetAutoComplete(new PRRequest()
		{
			autoCompleteSetBy = new Creator(){ id = pullRequest.CreatedBy.id }
		}, target.Owner,
		repo.id,
		pullRequest.PullRequestId);
}

Naming could be better :)

@stale
Copy link

stale bot commented Dec 24, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Dec 24, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants