asyncapi / .github

Location of all reusable community health files
29 stars 63 forks source link

[FEATURE] Would be nice to have bot be able to move issues between repositories #311

Open Souvikns opened 1 week ago

Souvikns commented 1 week ago

Why do we need this improvement?

To move a issue from one repo to another, you need to be codeowner to both the repositories that you are trying to move. Which is however not possible, so a bot command that does that would be awesome.

Issues like https://github.com/asyncapi/cli/issues/1488 cannot be transfered because there is no common codeowner between CLI and modelina.

How will this change help?

Repositories that implement other AsyncAPI tools like CLI. When encounterd bug most of the time it has to do with something with the underlying library. So to be able to move the issue to the right repo, helps in solving the problem faster.

Screenshots

No response

How could it be implemented/designed?

A simple bot command like /rtm that accepts the repo name to move as a input. Something like /mv modelina. Would be nice if only code owner of the repo could run this command.

🚧 Breaking changes

No

👀 Have you checked for similar open issues?

🏢 Have you read the Contributing Guidelines?

Are you willing to work on this issue?

Yes I am willing to submit a PR!

derberg commented 1 week ago

best would be to reflect the the name of the feature in the command name so /transfer-issue and /ti

derberg commented 1 week ago

here are examples how workflow for commands in issues look like:

so yeah, add new workflow file, with suffix command and use actions/github-script as above examples

also this help command needs to be updated

asyncapi-bot commented 1 week ago

Hello, @derberg! 👋🏼

I'm 🧞🧞🧞 Genie 🧞🧞🧞 from the magic lamp. Looks like somebody needs a hand!

At the moment the following comments are supported in issues:

derberg commented 1 week ago

and yeah, as you can see above, switch approach to startsWith instead of contains in case of your command, as contains causes that bot pick up for example help command if it is just part of the URL in the comment as in my last comment

Souvikns commented 1 week ago

I couldn't find any REST API endpoint that transfers issues, but gh cli can do that https://cli.github.com/manual/gh_issue_transfer and also a graphql mutation that can do this https://docs.github.com/en/graphql/reference/mutations#transferissue