Skip to content

Commit

Permalink
Fix the Monospace Issue
Browse files Browse the repository at this point in the history
Backport the upstream fix (was 98aed4e ).
  • Loading branch information
oldsharp committed Aug 13, 2015
1 parent 918df82 commit 9186909
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions book/10-git-internals/sections/refspec.asc
Original file line number Diff line number Diff line change
Expand Up @@ -61,11 +61,11 @@ From [email protected]:schacon/simplegit
* [new branch] topic -> origin/topic
----

在这个例子中,对 master 分支的拉取操作被拒绝,因为它不是一个可以快进的引用。
在这个例子中,对 `master` 分支的拉取操作被拒绝,因为它不是一个可以快进的引用。
我们可以通过在引用规格之前指定 `+` 号来覆盖该规则。

你也可以在配置文件中指定多个用于获取操作的引用规格。
如果想在每次获取时都包括 master 和 experiment 分支,添加如下两行:
如果想在每次获取时都包括 `master``experiment` 分支,添加如下两行:

[source,ini]
----
Expand All @@ -83,7 +83,7 @@ fetch = +refs/heads/qa*:refs/remotes/origin/qa*
----

但我们可以使用命名空间(或目录)来达到类似目的。
假设你有一个 QA 团队,他们推送了一系列分支,同时你只想要获取 master 和 QA 团队的所有分支而不关心其他任何分支,那么可以使用如下配置:
假设你有一个 QA 团队,他们推送了一系列分支,同时你只想要获取 `master` 和 QA 团队的所有分支而不关心其他任何分支,那么可以使用如下配置:

[source,ini]
----
Expand Down Expand Up @@ -129,4 +129,4 @@ $ git push origin master:refs/heads/qa/master
$ git push origin :topic
----

因为引用规格(的格式)是 `<src>:<dst>`,所以上述命令把 `<src>` 留空,意味着把远程版本库的 topic 分支定义为空值,也就是删除它。
因为引用规格(的格式)是 `<src>:<dst>`,所以上述命令把 `<src>` 留空,意味着把远程版本库的 `topic` 分支定义为空值,也就是删除它。

0 comments on commit 9186909

Please sign in to comment.