创建git远程服务器_在远程服务器上创建它后如何拉你的git树

创建git远程服务器

Currently, I have created my branch dev-harry but I cannot pull it successfully as follows.

目前,我已经创建了我的分支 dev-harry,但是无法按以下方式成功将其拉出。

harryxiyou@common_vm ~/forest/kvplus/kvplus $ git branch
* dev-harry
master
rc

harryxiyou @ common_vm〜/ forest / kvplus / kvplus $ git分支
*开发

rc

harryxiyou@common_vm ~/forest/kvplus/kvplus $ git pull
You asked me to pull without telling me which branch you
want to merge with, and ‘branch.dev-harry.merge’ in
your configuration file does not tell me, either. Please
specify which branch you want to use on the command line and
try again (e.g. ‘git pull ‘).
See git-pull(1) for details.

harryxiyou @ common_vm〜/ forest / kvplus / kvplus $ git拉
你要我拉不告诉你
合并 ,并在其中合并 “ branch.dev-harry.merge”
您的配置文件也没有告诉我。 请
在命令行上指定要使用的分支,然后
再试一次(例如'git pull')。
有关详细信息,请参见git-pull(1)。

If you often merge with the same branch, you may want to
use something like the following in your configuration file:

如果您经常与同一分支合并,则可能需要
在配置文件中使用以下内容:

[branch "dev-harry"]
remote = <nickname>
merge = <remote-ref>

[remote "<nickname>"]
url = <url>
fetch = <refspec>

See git-config(1) for details.

有关详细信息,请参见git-config(1)。

However, when I checkout to rc branch, it works well. I am looking for the reasons.

但是,当我签出到rc分支时,它运行良好。 我正在寻找原因。

harryxiyou@common_vm ~/forest/kvplus/kvplus $ git checkout rc
Switched to branch ‘rc’
Your branch is behind ‘origin/rc’ by 3 commits, and can be fast-forwarded.

harryxiyou @ common_vm〜/ forest / kvplus / kvplus $ git checkout rc
切换到分支“ rc”
您的分支落后“ origin / rc” 3次提交,并且可以快速转发。

harryxiyou@common_vm ~/forest/kvplus/kvplus $ git pull
Updating 4ada91a..732d9b7
Fast-forward
src/kv.c0 | 60 ++++++++++++++++++++++++————————————
1 files changed, 24 insertions(+), 36 deletions(-)

harryxiyou @ common_vm〜/ forest / kvplus / kvplus $ git拉
正在更新4ada91a..732d9b7
快进
src / kv.c0 | 60 ++++++++++++++++++++++++++ ————————————
更改1个文件 ,插入24个(+),删除36个(-)

Usually, adding these lines to .git/conf is fine:

通常,将这些行添加到.git/conf就可以了:

[branch "dev-harryxiyou"]
	remote = origin
	merge = refs/heads/dev-harryxiyou
Answered by Eric Z Ma.
埃里克·马(Eric Z Ma)回答。

翻译自: https://www.systutorials.com/how-to-pull-your-git-tree-after-creating-it-on-remote-server/

创建git远程服务器

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值