Open earthbound19 opened 5 years ago
We use https://github.com/octokit/rest.js#readme under the hood and just pass it a list of assignees: https://github.com/node-gh/gh/blob/master/lib/cmds/issue.js#L352 to the edit
endpoint.
However, their api endpoints have since updated and seem to be more granular.
We have not updated to their latest version yet so resolving this quickly is unlikely. I am in the process of building out our test suite so that we can confidently make sweeping changes like this.
To implement with their new api, we would probably have to list all assignees and then pass that list of assignees to the removeAssignees
endpoint: https://octokit.github.io/rest.js/#api-Issues-removeAssignees
Just finished upgrading to their new api so this is possible now! https://octokit.github.io/rest.js/
I found that I can remove all assignees from a closed issue with a command like this, run from the directory of the git repo with an associated GitHub remote:
gh is --assign --assignee "" --number 362
--which may not have been any behavior that was intended for
gh
. What I want is an--unassign-all
switch (feature request I suppose, unless it is intended behavior for an empty string assignee to remove all assignees).Meanwhile, some side effects of this is that it reopened the issue and removed labels from the issue, and I don't want it doing either of those things--I want it to do only what I tell it to.
I don't know whether GitHub's API is making those (presumptuous) choices or
gh
. If the former this is not an issue withgh
.