<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ThinkChat2.0新版上線,更智能更精彩,支持會話、畫圖、視頻、閱讀、搜索等,送10W Token,即刻開啟你的AI之旅 廣告
                # Merge request conflict resolution > 原文:[https://docs.gitlab.com/ee/user/project/merge_requests/resolve_conflicts.html](https://docs.gitlab.com/ee/user/project/merge_requests/resolve_conflicts.html) * [Resolve conflicts: interactive mode](#resolve-conflicts-interactive-mode) * [Resolve conflicts: inline editor](#resolve-conflicts-inline-editor) * [Conflicts available for resolution](#conflicts-available-for-resolution) # Merge request conflict resolution[](#merge-request-conflict-resolution "Permalink") 當兩個分支具有無法自動合并的不同更改時,將發生合并沖突. 在大多數情況下,Git 能夠自動合并分支之間的更改,但是在某些情況下,Git 需要您的幫助來手動解決沖突. 通常,當人們更改同一文件的相同部分時,這是必需的. 在解決所有沖突之前,GitLab 將阻止合并請求. 沖突可以在本地解決,也可以在許多情況下在 GitLab 中解決(有關何時可用的信息,請參見可解決的[沖突](#conflicts-available-for-resolution) ). [![Merge request widget](https://img.kancloud.cn/94/09/9409e42643e35a70ea5512dcb0d5c30b_1950x240.png)](img/merge_request_widget.png) **注意:** GitLab 通過在未自動合并到目標分支的源分支中創建合并提交來解決沖突. 這允許在合并更改之前對合并提交進行檢查和測試,從而防止意外更改進入目標分支而無需檢查或破壞構建. ## Resolve conflicts: interactive mode[](#resolve-conflicts-interactive-mode "Permalink") 在 GitLab 8.11 中[引入](https://gitlab.com/gitlab-org/gitlab-foss/-/merge_requests/5479) . 單擊此按鈕將顯示有沖突的文件列表,突出顯示沖突部分: [![Conflict section](https://img.kancloud.cn/ee/27/ee27470a25f472f70a9704b7e6ba8ffc_2392x950.png)](img/conflict_section.png) 一旦所有沖突都標記為使用"我們的"或"他們的",則可以解決沖突. 這將執行合并請求的目標分支到源分支的合并,使用選擇的選項解決沖突. 如果源分支是`feature` ,目標分支是`master` ,則類似于執行`git checkout feature; git merge master` `git checkout feature; git merge master`本地`git checkout feature; git merge master` . ## Resolve conflicts: inline editor[](#resolve-conflicts-inline-editor "Permalink") [Introduced](https://gitlab.com/gitlab-org/gitlab-foss/-/merge_requests/6374) in GitLab 8.13. 合并沖突解決編輯器允許更復雜的合并沖突,需要用戶手動修改文件以解決沖突,才能從 GitLab 界面中解決. 使用**內聯編輯**按鈕打開編輯器. 確定更改后,請單擊" **提交到源"分支**按鈕. [![Merge conflict editor](https://img.kancloud.cn/f8/d3/f8d3b9e040d5c3c8bcaefb9ac4d3fd32_816x444.png)](img/merge_conflict_editor.png) ## Conflicts available for resolution[](#conflicts-available-for-resolution "Permalink") GitLab 允許解決以下所有條件均成立的文件中的沖突: * 該文件是文本,不是二進制 * 該文件采用 UTF-8 兼容編碼 * 該文件尚未包含沖突標記 * 添加了沖突標記的文件大小不超過 200 KB * 該文件在兩個分支中位于相同路徑下 如果該合并請求中有沖突的任何文件均不滿足所有這些條件,則無法在 UI 中解決該合并請求的沖突. 此外,GitLab 不會在路徑之外的重命名中檢測到沖突. 例如,這不會造成沖突:在分支`a`執行`git mv file1 file2` ; 在分支`b` ,執行`git mv file1 file3` . 而是,合并請求合并后,兩個文件都將出現在分支中.
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看