我正在与PyGithub合作,以获得对我自己的github回购的基本访问。大多数方法都需要一个“路径”,我不知道这是什么。我将在.get_contents()函数中使用哪些参数?简单的例子:
from github import Github
g = Github("***","***")
repo = g.get_user().get_repo("my_projects")
contents = repo.get_contents()发布于 2016-03-06 10:55:18
您需要传递以下参数:
path - string -内容路径。
ref - string -提交/分支/标记的名称。默认:存储库的默认分支(通常是主分支)
例如- repo.get_contents('config/version.rb','development')
请参阅更多这里
https://stackoverflow.com/questions/32918622
复制相似问题