使用github v3 API删除标记

时间:2011-08-30 17:38:58

标签: github-api

我可以按照their directions使用GitHub v3 API创建带注释的标签。我创建标记对象,然后创建ref对象。一切都很好。

我可以删除引用,如下所示:

curl -X DELETE -i -u 'myuser:mypassword' https://api.github.com/repos/:user/:repo/git/refs/tags/ben-test-310

不幸的是,这似乎还不够。如何使用API​​完全删除标记?

1 个答案:

答案 0 :(得分:2)

The current api supports this. It's called "deleting a ref" (delete_ref):

https://developer.github.com/v3/git/refs/#delete-a-reference

Here it is in the Ruby SDK also, just for example: https://octokit.github.io/octokit.rb/Octokit/Client/Refs.html