如何让 hudson 的 git 插件使用路径中的存储库名称来克隆存储库?
假设我有一个名为“stuff”的存储库。 [email protected]:mine/stuff.git
当我进行 git 克隆时从命令行启动此存储库,它会创建一个名为“stuff”的目录并将所有内容放入其中目录。
当我设置 hudson 使用 git 时,它将所有内容都放在目录中,
$hudson_home/jobs/myjob/workspace/*
工作区后面没有“东西”。只是东西里面的物品。
如何让 hudson 像命令行一样克隆存储库,即:
$hudson_home/jobs/myjob/workspace/stuff/*
我没有看到此选项,并且我不想更改默认工作区路径。
Let's say I have a repo called "stuff". [email protected]:mine/stuff.git
when I do a git clone of this repo from the command line, it creates a directory called "stuff" and puts everything in that directory.
When I set up hudson to use git, it puts everything in the directory
$hudson_home/jobs/myjob/workspace/*
with no "stuff" after workspace. Just the items inside of stuff.
How can I make hudson clone the repo like the commandline does, namely:
$hudson_home/jobs/myjob/workspace/stuff/*
I see no options for this and I do not want to change the default workspace path.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我不知道 Hudson 中是否有此功能,因为我已经升级到 Jenkins。
但是,如果您单击 Git 部分底部的“高级”(有两个“高级”按钮),就会有一个名为“Repo 的本地子目录”的属性,它可以满足您的需求。
I don't know whether this feature is in Hudson, since I have upgraded to Jenkins.
But if you click "Advanced" at the bottom of the Git section (there are two "Advanced" buttons), there is a property called "Local subdirectory for repo" which does what you want.