问题
Let's say I have a repo called "stuff". git@github.com: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.
回答1:
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.
来源:https://stackoverflow.com/questions/7520979/how-to-get-hudsons-git-plugin-to-clone-repo-with-the-name-of-the-repo-in-the-pa