让 hudson 将源签出到特定目录

发布于 2024-09-26 04:52:37 字数 1513 浏览 10 评论 0原文

这似乎是一个简单的任务,但在我的一生中,我无法让 Hudson 将我的源代码签出到特定目录。 我可以在命令行上使用 svn 查看源代码。 我尝试在源代码管理下指定本地模块设置,但没有骰子。

我将其设置为 c:\source\trunk 并在运行构建时得到此信息。

Started by user anonymous
Checking out http://mysvnserver/trunk
java.io.IOException: The filename, directory name, or volume label syntax is incorrect
    at java.io.WinNTFileSystem.canonicalize0(Native Method)
    at java.io.Win32FileSystem.canonicalize(Unknown Source)
    at java.io.File.getCanonicalPath(Unknown Source)
    at java.io.File.getCanonicalFile(Unknown Source)
    at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:742)
    at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:660)
    at hudson.FilePath.act(FilePath.java:753)
    at hudson.FilePath.act(FilePath.java:735)
    at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:653)
    at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:601)
    at hudson.model.AbstractProject.checkout(AbstractProject.java:1082)
    at hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:479)
    at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:411)
    at hudson.model.Run.run(Run.java:1280)
    at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:293)
    at hudson.model.ResourceController.execute(ResourceController.java:88)
    at hudson.model.Executor.run(Executor.java:137)
Finished: FAILURE

当我尝试设置相对路径时,它说我不能使用绝对目录。 即 \source\trunk

我想要发生的就是 hudson 将我的源签出到 c:\source\trunk

This seems like a simple task but for the life of me I can't get Hudson to checkout my source to a specific directory.
I can checkout the source using svn on the command line.
I tried specifying the Local Module setting under source code management but no dice.

I set it to c:\source\trunk and I get this when i run the build.

Started by user anonymous
Checking out http://mysvnserver/trunk
java.io.IOException: The filename, directory name, or volume label syntax is incorrect
    at java.io.WinNTFileSystem.canonicalize0(Native Method)
    at java.io.Win32FileSystem.canonicalize(Unknown Source)
    at java.io.File.getCanonicalPath(Unknown Source)
    at java.io.File.getCanonicalFile(Unknown Source)
    at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:742)
    at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:660)
    at hudson.FilePath.act(FilePath.java:753)
    at hudson.FilePath.act(FilePath.java:735)
    at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:653)
    at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:601)
    at hudson.model.AbstractProject.checkout(AbstractProject.java:1082)
    at hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:479)
    at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:411)
    at hudson.model.Run.run(Run.java:1280)
    at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:293)
    at hudson.model.ResourceController.execute(ResourceController.java:88)
    at hudson.model.Executor.run(Executor.java:137)
Finished: FAILURE

When i try to set a relative path it says I can't use absolute directories.
i.e \source\trunk

All i want to have happen is hudson checkout my source to c:\source\trunk

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

著墨染雨君画夕 2024-10-03 04:52:37

正如履行机构已经说过的那样:

像 SVN 这样的路径相对于
工作区根目录。至少就是这样
“本地模块目录”的帮助
作业配置页面上有说明。

当您以“\”开始路径时,意味着该路径是绝对路径。你有两个选择。

  1. 为您的工作定义自定义工作区。这可能是 c:\source 并且源的签出将是 trunk (或者如果签出您的 svn url 以“/trunk”结尾,则将其保留为空。
  2. 将其签出到您的标准工作区,然后将其复制到 C:\ 顺便说一句

,我倾向于第二个选项,因为我几乎不惜一切代价尝试避免自定义工作区。

As sbi already said:

Paths like the SVN are relative to the
Workspace root. At least that's what
the help for "Local module directory"
says on the Job configuration page.

When you start a path with '\' than it means that the path is absolute. You have two options.

  1. Define a custom workspace for your job. This could be c:\source and the checkout of the source would be to trunk (or leave it empty if checking out your svn url ends with '/trunk'.
  2. check it out to your standard workspace and then copy it to C:\source\trunk.

BTW, I would favor the second option, because I try to avoid the custom workspace at almost all costs.

仙气飘飘 2024-10-03 04:52:37

像 SVN 这样的路径相对于工作区根。至少作业配置页面上的“本地模块目录”帮助是这么说的。

Paths like the SVN are relative to the Workspace root. At least that's what the help for "Local module directory" says on the Job configuration page.

残疾 2024-10-03 04:52:37

另一个解决方法是在运行 Hudson 的同一系统中创建主从配置。在同一台机器上创建一个从属设备,并在从属配置中指向您希望项目检出的位置

The other workaround is to create MAster-Slave config in the same system on which Hudson is running. Create a slave on the same machine and point to the location where yu want yur projet to checkout in the Slave configuration

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文