gitdir icon indicating copy to clipboard operation
gitdir copied to clipboard

Does it work for private repos?

Open sdelquin opened this issue 6 years ago • 8 comments

I have access to my students's private repos, and i usually need to download specific folders of their repos. This tool seems great, but it apparently does not work with private repos (i do have access though).

sdelquin avatar Mar 06 '19 20:03 sdelquin

I have not tested this on private repos. But I think we would have to pass the credentials (username and password) with the requests in order for you to access the private repo. I will try find a way to make a way to let users login if it a private repo :)

sdushantha avatar Mar 07 '19 05:03 sdushantha

@sdelquin Do you know how to login to GitHub with Python? Im not able to do it for some reason.

sdushantha avatar Mar 07 '19 06:03 sdushantha

Not really :/

sdelquin avatar Mar 07 '19 19:03 sdelquin

@sdelquin I dont think private repos will work. Also, I dont plan to support private repos. :crying_cat_face:

sdushantha avatar May 25 '19 16:05 sdushantha

You can login to GitHub using the python GitHub API https://github.com/PyGithub/PyGithub

SelfhostedPro avatar Jun 13 '20 00:06 SelfhostedPro

@SelfhostedPro Very interesting! I will have to take a look at the documentation to see it is able to get files from a branch or get the files of folder in a the given repo

sdushantha avatar Jun 13 '20 07:06 sdushantha

This is something we have to be aware of: https://developer.github.com/changes/2020-02-14-deprecating-password-auth/

sdushantha avatar Jun 13 '20 07:06 sdushantha

PyGithub enables you to use Access tokens so you don't need to worry about that deprecation.

SelfhostedPro avatar Jun 13 '20 07:06 SelfhostedPro