Can't fetch private UPM Packages from github because can't add my github credentials to Unity
See original GitHub issueBug description We’re using private packages from github in the Unity Package Manager. Building does not work with this because Unity asks for my github credentials. On my local Windows machine, Github Crendetial Manager pops up and I can insert them. What do I have to do in an github action to add them?
- stderr: fatal: could not read Username for 'https://github.com': terminal prompts disabled
Project has invalid dependencies:
de.lefx.stepmanager: Error when executing git command. fatal: could not read Username for 'https://github.com': terminal prompts disabled
I’ve tried to add my github credentials with fusion-engineering/setup-git-credentials@v2.0.1 but does not work either.
How to reproduce
Try building a project with UPM dependency from a private github URL.
Expected behavior
Project builds 😃
Additional details
I’ve added my script and the logfiles
Issue Analytics
- State:
- Created 3 years ago
- Reactions:2
- Comments:19 (11 by maintainers)
Top Results From Across the Web
Github private repositories - Entering username and ...
I'm trying to load a private Github repository of mine. I'm getting the following error: Cannot perform upm operation: Unable to add package...
Read more >Installing from a Git URL
Open the add menu in the Package Manager's toolbar. · The options for adding packages appear.
Read more >Unity cant add git packages on external SSD. FATAL: not in ...
I've been having the same issue drive me crazy for weeks now. On my end, the issue was a combination of. the external...
Read more >How to setup GitHub packages and Unity - Enigma 23
Installing npm · GitHub Personal Access Token (PAT) · Setting up GitHub npm authentication · Create a GitHub repository · Creating a package.json...
Read more >Package Registry - GitLab Docs
If you have not activated the “Packages” feature for your project at Settings > General > Project features, you will receive a 403...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
That’s a fair point and thank you for elaborating on your use case, this is very helpful.
I suppose we could add gitUser and gitPassword as parameters and pass them into the image.
I believe unity has specific ENV variables it wants to use for UPM.
Open for contributions.
I see. If that is GitHub official answer (for now) then so is ours. I stand corrected. Conceptually though not everyone has their own tokens for CI, just the person setting it up configures a token. Not sure if this is obvious for everyone or not.
As for the cases let’s also consider:
That is to say that I think we’d like to support a similar solution as the one you proposed, as long as it works for everyone or is forward compatible with all cases in some way.
Finally, let’s see how much of the problem would get solved by https://github.com/game-ci/unity-builder/pull/278/files or how much of that PR can be reused.
Thank you for your extended explanation and consideration. 😃