unstorage icon indicating copy to clipboard operation
unstorage copied to clipboard

Github private repo explanation

Open stijns96 opened this issue 1 year ago • 3 comments

Describe the change

I have to get some content of my private Github repository. I know you can add a token, but it would be nice to explain how to do this.

I struggled a little bit on how to get the token and what kind of scopes it needs in order to make it work with Unstorage.

URLs

https://unstorage.unjs.io/drivers/github

Additional information

  • [ ] Would you be willing to help?

stijns96 avatar Nov 29 '24 09:11 stijns96

Would you like to make a PR to the docs sharing your experience? 🙏🏼

pi0 avatar Nov 29 '24 09:11 pi0

Hi @pi0,

I would, but I'm not really sure if I did it the right way... Here some more context:

I'm working on a docs for the company I'm working for that is build with Nuxt / Nuxt Content. Now I used a personal access token, but that feels a bit weird to do. I think that I have to go for a Github App, but haven't worked with that yet.

Could you maybe direct me a little bit to some best practices? Then I can figure out if that is working and then create a PR.

Since you're also working on Nuxt (I recognize your name), you probably know a bit more on how to do this then I do at this point... Haha

stijns96 avatar Nov 29 '24 10:11 stijns96

PAT or better fine gained personal tokens are good (we don't support github app). Feel free to start a draft I can help to finish it.

pi0 avatar Nov 29 '24 10:11 pi0