本文主要是介绍Source Code Management--(SCM in gitlab),希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
Source Code Management
Introduction and how you can help
The Source Code Management direction page belongs to the Source Code group of the Create stage, and is maintained by Derek Ferguson, who can be reached at dferguson@gitlab.com.
This direction is a work in progress, and everyone can contribute. Sharing your feedback directly is the best way to contribute to our strategy and vision. Please, comment and contribute in the linked issues below, or to any other issues or epics, or raise an issue yourself in gitlab-org/gitlab if you don't find existing feedback that matches your thoughts.
源代码管理
简介以及如何提供帮助
“源代码管理”方向页面属于“创建”阶段的“源代码”组,由 Derek Ferguson 维护,可通过 dferguson@gitlab.com 联系到他。
这个方向是一个正在进行的工作,每个人都可以做出贡献。直接分享您的反馈是为我们的战略和愿景做出贡献的最佳方式。请在下面的链接问题或任何其他问题或史诗中发表评论和贡献,或者如果您没有找到与您的想法相匹配的现有反馈,请在 gitlab-org/gitlab 中自行提出问题。
Strategy and Themes
Source code management (SCM) is the foundation of an organization's software development practice.
Building great software depends on teams working well together. Teams can rarely be divided into areas of complete independence. As cross-functional security, compliance, and growth teams are formed, or new services and libraries are created, effective coordination and collaboration are essential.
To achieve this, teams need to protect production while making it easy for everyone to contribute. Source Code Management provides the controls to define the rules and workflows for this purpose:
- Who has the rights to view or change the code (visibility; members; permissions; merge request approvals; forking and mirroring)
- Who owns the code and is responsible for it and thus has the right to approve changes to it (codeowners; merge request approvals)
- Which quality tests must be passed before changes can be applied (coverage checks; security checks)
- Which branches need to be protected because they influence production (default branch; protected branches; push rules)
战略和主题
源代码管理 (SCM) 是组织软件开发实践的基础。
构建出色的软件取决于团队的良好合作。团队很少可以划分为完全独立的区域。随着跨职能安全、合规性和增长团队的形成,或者新服务和库的创建,有效的协调和协作至关重要。
为了实现这一目标,团队需要保护生产,同时让每个人都能轻松做出贡献。源代码管理提供了用于定义规则和工作流的控件,以实现此目的:
- 谁有权查看或更改代码(可见性;成员;权限;合并请求批准;分叉和镜像)
- 谁拥有代码并对其负责,因此有权批准对代码的更改(代码所有者;合并请求审批)
- 在应用更改之前必须通过哪些质量测试(覆盖率检查;安全检查)
- 哪些分支需要保护,因为它们会影响生产(默认分支;受保护的树枝;推送规则)
Themes
While the principles have been around for half a century, SCM is not without challenges. SCM needs to address a large set of requirements that are partly contradicting:
- encourage sound development practices
- but also, be flexible enough to adjust to varying workflows
- be intuitive
- but also, be secure and ensure compliance
- be fast and reliable
- but easy to manage
主题
虽然这些原则已经存在了半个世纪,但 SCM 并非没有挑战。SCM 需要解决大量部分矛盾的需求:
- 鼓励健全的发展实践
- 而且,要足够灵活,以适应不同的工作流程
- 要直观
- 而且,要确保安全并确保合规性
- 快速可靠
- 但易于管理
Git is the leading Version Control System (VCS) and is loved by developers. It excels at tracking changes in source code and makes it easy and transparent to merge changes from different developers into one code base. GitLab's source code management builds on top of Git adding functionality that aims to address the above requirements. For example, access control to code repositories or requiring code reviews before merging changes. Source code management and the create stage represent the most popular features in GitLab.
Git 是领先的版本控制系统 (VCS),深受开发人员的喜爱。它擅长跟踪源代码中的更改,并使将来自不同开发人员的更改合并到一个代码库中变得简单透明。GitLab 的源代码管理建立在 Git 之上,添加了旨在满足上述要求的功能。例如,对代码存储库的访问控制或要求在合并更改之前进行代码审查。源代码管理和创建阶段代表了 GitLab 中最受欢迎的功能。
Yet, despite their appeal, neither Git nor GitLab SCM are perfect. Here are the current main shortcomings:
- GitLab's SCM UX, has shown to be partly unintuitive or uninformative. For instance, controls to enforce rules are hard to discover and understand.
- Git is not particularly good at working with binary files such as graphics or video content common in game development. With those media files, Git cannot interpret change on a granular level as it does with text files. So, it needs to store full copies of every new version of a media file.
- While Git Large File Storage (LFS) aims to address this, the Git process - as helpful as it is for developers - appears complex from a content creator's perspective. Especially as they cannot benefit in the same way from Git as developers do for the lack of diffability of media files.
- Finally, Git gets slow when repositories become exceptionally large (even if they do not contain binary files). While not common such so-called monorepos are used in several large tech companies. Partial clone addresses some of the issues.
然而,尽管它们很有吸引力,但 Git 和 GitLab SCM 都不是完美的。以下是目前的主要缺点:
- GitLab 的 SCM UX 已被证明部分不直观或信息不足。例如,强制执行规则的控件很难发现和理解。
- Git 并不特别擅长处理二进制文件,例如游戏开发中常见的图形或视频内容。对于这些媒体文件,Git 无法像处理文本文件那样在粒度级别上解释更改。因此,它需要存储媒体文件的每个新版本的完整副本。
- 虽然 Git Large File Storage (LFS) 旨在解决这个问题,但从内容创建者的角度来看,Git 流程(尽管对开发人员很有帮助)似乎很复杂。特别是因为他们无法像开发人员那样从 Git 中受益,因为媒体文件缺乏可传播性。
- 最后,当存储库变得非常大时(即使它们不包含二进制文件),Git 会变慢。虽然不常见,但这种所谓的 monorepos 在几家大型科技公司中使用。部分克隆解决了一些问题。
Strategy
Therefore, the vision for Source Code Management at GitLab consists of three pillars:
- Make it easy and intuitive to manage source code so that it is secure, compliant, and encourages best development practices.
- Make it easy to work with large binary files in GitLab. And make it easy for content creators to contribute media files to GitLab to enable better collaboration with developers to support GitLab's mission: everyone can contribute!
- Make it easy to work with monorepos in GitLab: &8262. (Note, this also touches other stages, especially the Verify stage).
策略
因此,GitLab 的源代码管理愿景由三大支柱组成:
- 轻松直观地管理源代码,使其安全、合规,并鼓励最佳开发实践。
- 在 GitLab 中轻松处理大型二进制文件。让内容创作者可以轻松地向 GitLab 贡献媒体文件,以便与开发人员更好地协作,以支持 GitLab 的使命:每个人都可以贡献!
- 在 GitLab 中使用 monorepos 变得容易:&8262。(请注意,这也涉及其他阶段,尤其是“验证”阶段)。
Note: SCM is not only the most used function in GitLab but also the one with the longest history as it has been there from the beginning. As a result, we get a lot of feedback and have a long backlog of issues. Therefore, we need to spend a considerable share of our teams’ capacity on issues that are not at the center of this vision but address bugs, stability, security, and scalability to keep our users and customers happy.
注意:SCM 不仅是 GitLab 中最常用的函数,也是历史最悠久的函数,因为它从一开始就存在。因此,我们收到了很多反馈,并积压了很长时间的问题。因此,我们需要将团队能力的相当一部分用于不是这一愿景核心的问题,而是解决错误、稳定性、安全性和可扩展性,以保持我们的用户和客户满意。
摘自:
分类方向 - 源代码管理 | GitLab的
这篇关于Source Code Management--(SCM in gitlab)的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!