GitHub:为什么要分叉?

编程入门 行业动态 更新时间:2024-10-25 22:34:33
本文介绍了GitHub:为什么要分叉?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我明白分叉是在服务器端克隆存储库。但我不明白为什么我会那么做。

为什么不将原始存储库克隆到我的机器上,添加我的代码,而不是将新分支推送到GitHub并使一个拉请求?

解决方案

从Github文档

是存储库的副本。分叉存储库允许您在不影响原始项目的情况下自由地尝试更改。

最常见的情况是,叉子用于向其他人的项目提出更改或使用其他人的项目项目作为你自己想法的起点。

help.github/articles/fork-a-repo/

I understand that forking is cloning the repository on the server side. But I don't understand why I would do that.

Why not clone the original repository to my machine, add my code, than push the new branch to GitHub and make a pull request?

解决方案

From the Github documentation

A fork is a copy of a repository. Forking a repository allows you to freely experiment with changes without affecting the original project.

Most commonly, forks are used to either propose changes to someone else's project or to use someone else's project as a starting point for your own idea.

help.github/articles/fork-a-repo/

更多推荐

GitHub:为什么要分叉?

本文发布于:2023-07-04 17:24:56,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1027054.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:GitHub

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!