>你要求从遥远的' - 普朗' [英] > You asked to pull from the remote '--prune'

查看:103
本文介绍了>你要求从遥远的' - 普朗'的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

使用我的其中一个别名时出现此错误 bdone


您要求从远程'--prune'拉,但没有指定
分支。因为这不是您的
当前分支的默认远程配置,您必须在命令行中指定一个分支。


这是我使用的别名

  alias.bclean!f(){git branch --merged $ {1-master} | grep -v $ {1-master} $ | xargs git branch -d; }; f 
alias.bdone!f(){git checkout $ {1-master}&& git up&& git bclean $ {1-master}; }; f

我没有提交任何内容 code>

解决方案


您要求从远程' - prune ',但未指定分支


这意味着远程名称为空,并将下一个命令行参数(这里是 - prune )解释为(错误地)作为远程名称。

这可能是 git-up.rb ,但是项目git up 不再被维护。它说:


从Git 2.9开始, git pull --rebase --autostash 基本上是一样的。


所以,如果你有

  git config --global pull.rebase true 
git config --global rebase.autoStash true

然后您可以将 git up 由一个简单的经典 git pull


I'm getting this error when using one of my aliases bdone

You asked to pull from the remote '--prune', but did not specify a branch. Because this is not the default configured remote for your current branch, you must specify a branch on the command line.

This is the alias I use

alias.bclean !f() { git branch --merged ${1-master} | grep -v  ${1-master}$ | xargs git branch -d; }; f
alias.bdone !f() { git checkout ${1-master} && git up && git bclean ${1-master}; }; f

I have nothing to commit nothing to commit, working directory clean

解决方案

You asked to pull from the remote '--prune', but did not specify a branch

That means the remote name was empty, and the next command-line parameter (here --prune) was interpreted (wrongly) as the remote name.

This may be a bug in git-up.rb, but the project git up is not maintained anymore. It says:

As of Git 2.9, git pull --rebase --autostash does basically the same thing.

So, if you have git 2.9 or more, do:

git config --global pull.rebase true
git config --global rebase.autoStash true

Then you can replace git up by a simple classic git pull.

这篇关于>你要求从遥远的' - 普朗'的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆