Gud插件Hudson签出问题 [英] Git plugin for Hudson checkout problem
问题描述
$ b在使用Gud插件用于Hudson时,我的作业总是失败,从我的在线git存储库中获取最新源代码(git://github.com/ithena/orm2dsl.git)。 $ b
git插件首先成功执行 git fetch
。然后它会尝试执行 git checkout -f origin /
,它会失败,如下所示。这是我的git存储库的问题吗?或者它是没有意义的检出命令?
没有在作业配置中设置分支的Git命令:
git checkout -f origin /
git checkout:更新路径与切换分支不兼容/强制
您是否打算签出无法解析为提交的'origin /'?
在分配设置为master的Git命令中
git checkout -f origin / master
git checkout:更新路径与切换分支不兼容/强制
完成你打算签出无法解析为提交的origin / master?
哈德森控制台输出:
开始
结账
[工作区] $ git fetch
检出原点/
[工作区] $ git checkout -f原产地/
git checkout:更新路径与切换分支不兼容/强制
您是否打算签出无法解析为提交的origin /?
致命错误:检出原点/
错误java.lang.RuntimeException:在hudson.plugins.git.GitAPI.launch(GitAPI.java:101)$ b $检出原点/
时出错b在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)
Hudson环境: Debian Etch,Sun JSDK 6,git 1.4.4.4,hudson最新稳定版下载
首先,你的Git版本很旧。
其次, git checkout -f origin /
不是一个有效的命令。你可能需要签出一个分支,或者你可以签出一个提交(通过指定提交哈希或标签)并在同一处创建一个新的分支(使用 git checkout -b新分支提交-hash
)。详情请参阅 git-checkout手册页面。
When using the Git plugin for Hudson my job always fails when fetching the latest sources from my online git repository ( git://github.com/ithena/orm2dsl.git ) .
The git plugin first executes git fetch
succesfully. Then it tries to execute git checkout -f origin/
, which fails as shown below. Is this a problem with my git repository or is it the checkout command that makes no sense?
Git command whithout a branch set in the job configuration:
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 command with branch set to master in the job configuration:
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?
Hudson console output:
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)
Hudson Environment: Debian Etch, Sun JSDK 6, git 1.4.4.4, hudson latest stable download
First, your version of Git is pretty old. I suggest you update it before you do anything else.
Second, git checkout -f origin/
is not a valid command. You either need to checkout a branch, or you can checkout a commit (by specifying the commit hash or a tag) and create a new branch of it at the same (using git checkout -b new-branch commit-hash
). See the git-checkout man page for further details.
这篇关于Gud插件Hudson签出问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!