I've searched and searched, but I couldn't find a tutorial or article on how to use Visual Studio 2022 with a different git server other than Github or Azure DevOps.
When trying to add a solution to source control and want it to create a new repository on our gitea server, I presume I have to use the 'existing remote' option:
but what URL do I need to add here? I tried something like 'https://git.myserver.net/myusername' even tried to a repository 'https://git.myserver.net/myusername/myrepository.git' but none works (it also doesn't ask for credentials anywhere). When I try to push the project to master I get the following:
A new Git repository has been created for you in C:\Source\VS.NET 2022\MyExampleVB. Open the Git Repository window to view its contents.
Opening repositories:
C:\Source\VS.NET 2022\MyExampleVB
Opening repositories:
C:\Source\VS.NET 2022\MyExampleVB
Commit 757a3115 created locally in repository C:\Source\VS.NET 2022\MyExampleVB
Opening repositories:
C:\Source\VS.NET 2022\MyExampleVB
Opening repositories:
C:\Source\VS.NET 2022\MyExampleVB
Pushing master
Error encountered while pushing branch to the remote repository: Git failed with a fatal error.
Git failed with a fatal error.
unable to access 'https://git.myserver.net/myuser/': Failed to connect to git.hrbox.net port 443 after 21087 ms: Timed out
Failed to push the branch to the remote repository. See the Output window for more details.
I only used git with github or Azure DevOps in the past, but the company apparently doesn't want to use either and therefore setup their own gitea server.
Thanx for all comments. In the end there were several problems:
And the way to use a server other then Github or DevOps is by using the 'Existing remote' option and enter a new repository name which does not exist on the server yet:
When it's the first time, it will ask for credentials for your userlogin on that specific server when you push the project onto the server.