Tell UPM to look for package.json in given folder/path of a given branch of a given git url

I am developing and maintaining a personal-use-only custom-package “com.a” by testing it in regular unity project “TestProjectA” and then push everything to git at url TestProjectA (Akshay Yadav ) · GitHub

Structure of git branch named “package_ver1” as below:
TestProjectA/TestProjectA.sln
TestProjectA/Assets/TestScene.unity
TestProjectA/Assets/TestScript.cs
TestProjectA/Packages/manifest.json
TestProjectA/Packages/package-lock.json
TestProjectA/Packages/com.a/package.json
TestProjectA/Packages/com.a/Runtime/Sample.cs
TestProjectA/Packages/com.a/Runtime/com.a.asmdef

With above, I’ve imported “com.a” as a local-dependency in TestProjectA, currently I’m able to edit and test Sample.cs and push whole project to git.

Question:
When I import “com.a” package in live projects, like LiveProject1 or LiveProject2, is there a way to tell UPM to search of package.json in folder/path like "./Packages/com.a/’ on branch “package_ver1” of git url TestProjectA (Akshay Yadav ) · GitHub ?

1 Like

thanks @KyryloKuzyk … while I tried this previously through this same documentation, it wasn’t working. I found the issue though; my global git config credential.helper = osxkeychain did not work. Later I tried git-credential-manager and it worked with unity showing the login pop-up. Now I’m able to use TestProjectA (Akshay Yadav ) · GitHub and it works!