在使用Git的插件哈德森我的工作从获取我的网上的git库中的最新源时总是失败。(GIT://github.com/ithena/orm2dsl.git)

在GIT中的插件第一成功地执行git fetch。然后,它试图执行git checkout -f origin/,如下所示,其将失败。这是我的git仓库还是结账的命令,是没有意义的?

<强> GIT中命令一个内部消除分支在任务配置设置:

git checkout -f origin/
git checkout: updating paths is incompatible with switching branches/forcing
Did you intend to checkout 'origin/' which can not be resolved as commit?

<强>与分支在作业构型设置为主GIT中的命令:

git checkout -f origin/master
git checkout: updating paths is incompatible with switching branches/forcing
Did you intend to checkout 'origin/master' which can not be resolved as commit?

<强>哈德森控制台输出:

started
Checkout
[workspace] $ git fetch
Checking out origin/
[workspace] $ git checkout -f origin/
git checkout: updating paths is incompatible with switching branches/forcing
Did you intend to checkout 'origin/' which can not be resolved as commit?
FATAL: Error checking out origin/
java.lang.RuntimeException: Error checking out origin/
    at hudson.plugins.git.GitAPI.launch(GitAPI.java:101)
    at hudson.plugins.git.GitAPI.checkout(GitAPI.java:94)
    at hudson.plugins.git.GitSCM.checkout(GitSCM.java:90)
    at hudson.model.AbstractProject.checkout(AbstractProject.java:693)
    at hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:266)
    at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:239)
    at hudson.model.Run.run(Run.java:842)
    at hudson.model.Build.run(Build.java:88)
    at hudson.model.ResourceController.execute(ResourceController.java:70)
    at hudson.model.Executor.run(Executor.java:90)

哈德森环境:的是Debian Etch,孙JSDK 6,混帐1.4.4.4,哈德森最新的稳定版本

有帮助吗?

解决方案

首先,你的Git版本是很老。我建议你更新你做任何事情之前。

其次,git checkout -f origin/不是有效的命令。您可能需要签一个分支,也可以检出提交(通过指定提交散列或标签),并在同一(使用git checkout -b new-branch commit-hash)创建它的一个新的分支。请参阅 GIT中结账人页进一步的细节。

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top