如何通过github API在github中创建仓库? [英] How to create repository in github through github API?

查看:1353
本文介绍了如何通过github API在github中创建仓库?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用github API在特定组织下创建存储库。我正在查看这个网站,该网站介绍了如何在特定组织下创建存储库。

 在这个组织中创建一个新的存储库。经过身份验证的用户必须是指定组织的成员。 
POST / orgs /:org / repos

现在我无法理解会发生什么是我需要用于在特定组织中创建存储库的完整URL吗?我有我的用户名和密码,我可以通过https url在组织下创建存储库。



我的github实例url是这样的 - https://github.host.com



我想让我的仓库在创建后就像这样 -

  https://github.host.com/Database/ClientService 

我的curl命令看起来像是在一个组织中创建仓库的目录? >您需要的所有信息 此处 ,在gihub帮助页面描述

https://developer.github.com/guides/getting-started/#create-a-repository


I am trying to use github api to create repositories under a particular organization. I was looking at this site which talks about how to create repositories under a particular organization.

Create a new repository in this organization. The authenticated user must be a member of the specified organization.
POST /orgs/:org/repos

Now I am not able to understand what will be my full URL that I need to use to create the repository under a particular organization? I have my username and password which I can use to create the repository under an organization through https url.

My github instance url is like this - https://github.host.com

And I want my repository to be like this after getting created -

https://github.host.com/Database/ClientService

What will be my curl command look like to create the repository under an organization?

解决方案

All the information you need is here, describes in the gihub help pages

https://developer.github.com/guides/getting-started/#create-a-repository

这篇关于如何通过github API在github中创建仓库?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆