gpt4 book ai didi

c# - 如何从 Visual Studio 2017 将现有解决方案添加到 GitHub?

转载 作者:IT王子 更新时间:2023-10-29 04:47:54 26 4
gpt4 key购买 nike

我想将我现有的解决方案添加到 Github,并且我观看了很多 youtube 视频。但所有这些都只向我展示了创建新项目的过程。如何在 Github 上添加现有项目? Visual Studio 2017 Community Edition 中没有文件-> 添加到源代码管理选项!

最佳答案

您可以通过以下步骤实现:

1.Open the solution in Visual Studio 2017
2.Select File | Add to Source Control
3.Select the Microsoft Git Provider

创建本地 GIT 存储库

1.Browse to GitHub
2.Create a new repository DO NOT SELECT Initialize this repository with a README

这会创建一个没有主分支的空仓库

1.Once created open the repository and copy the URL (it's on the right of the screen in the current version)
2.Go back to Visual Studio
Make sure you have the Microsoft Git Provider selected under Tools/Options/Source Control/Plug-in Selection
3.Open Team Explorer
4.Select Home | Unsynced Commits
5.Enter the GitHub URL into the yellow box (use HTTPS URL, not the default shown SSH one)
6.Click Publish
7.Select Home | Changes
8.Add a Commit comment
9.Select Commit and Push from the drop down

我希望这对您有所帮助,您的解决方案现在在 Github 中

关于c# - 如何从 Visual Studio 2017 将现有解决方案添加到 GitHub?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42217847/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com