unjs / giget

✨ Download templates and git repositories with pleasure!
MIT License
446 stars 37 forks source link

Failed to download template 404 #100

Closed amiruddinid closed 11 months ago

amiruddinid commented 1 year ago

Environment

v16.13.1 v18.16.0 v20.5.0

Reproduction

npx giget@latest gh:withastro/astro/examples/basics my-project npx giget@latest gh:unjs/template

Describe the bug

Screenshot 2023-08-08 at 10 56 01

Additional context

The github link can be downloaded using wget or browser

Logs

No response

amiruddinid commented 1 year ago

I think its related to this PR : #93

Alkaidcc commented 11 months ago

same issue

nlaitchison commented 11 months ago

Same issue too

pi0 commented 11 months ago

Sorry for late check on this. It will be solved in next release thanks to PR (https://github.com/unjs/giget/pull/93) by @ishanjain28 ❤️

Note: You need to provide --auth or GIGET_AUTH env with token.

letoast commented 2 months ago

@pi0 I also get 404 on anything I try

➜  projects npx gitget@latest gh:unjs/template   
⠕ Starting: gitget
⠕ User: gh:unjs
⠕ Repo: template
⠕ StatusCode: 404
⨯ Not Found
➜  projects npx gitget@latest gh:unjs/template/test
⠕ Starting: gitget
⠕ User: gh:unjs
⠕ Repo: template
⠕ Subdir: test
⠕ StatusCode: 404
⨯ Not Found

Using an URL however works, but only for public repos:

➜  projects npx gitget@latest https://github.com/unjs/template
⠕ Starting: gitget
⠕ User: unjs
⠕ Repo: template
⠕ StatusCode: 200
⠕ Default Branch: main
⠕ Tag/Branch/Commit: main
⠕ Downloading: https://github.com/unjs/template/archive/main.tar.gz
⠕ StatusCode: 302
⠕ StatusCode: 200
⠕ Clean: remove tmp files
√ Done! Your repo is in /template.
➜  projects npx gitget@latest https://github.com/letoast/nuxt-image-gallery --auth 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
⠕ Starting: gitget
⠕ User: letoast
⠕ Repo: nuxt-image-gallery
⠕ StatusCode: 404
⨯ Not Found