-
Notifications
You must be signed in to change notification settings - Fork 119
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FIXED JENKINS-14862] add option to get the whole repository on clone/pull #46
Conversation
if you want to build a tag it is necessary to pull the whole repository --HG-- extra : rebase_source : 7c4271d08177328e9686a1c2059cb01f1c4f515e extra : amend_source : 60c844565e12643721edc28f8635cd1787eaf490
Jenkins » mercurial-plugin #132 FAILURE |
Jenkins » mercurial-plugin #133 FAILURE |
Adding this flag to And a pull request should include a new test that fails (in all the expected ways) without the change and passes with it. In this case I would expect to see a test method in |
As mentioned in #20, when caching is on, probably the |
From a UI perspective adding an option to “clone the whole repository” is also probably the wrong approach; it forces the user to think about the plugin’s implementation. What the user really needs to say is that the Branch field is actually referring to a tag. So probably what the UI should have is a dropdown next to this field that lets the user say what they are entering:
Then it is up to the plugin to adjust its behavior according to the kind of update target. Currently that might mean nothing more than omitting |
I may have done it wrong, or have an older version of the plugin, but I thought that when caching was on, it just meant that Jenkins had a local copy of the repository in a general workspace area and then jobs cloned from THAT repository, so it wasn't hard-linked. I was assuming that the point of this was to minimize time to clone (because the repository the jobs were cloning from was local) rather than optimizing for disk space. In any case, I like this feature, thanks for implementing it :). |
When caching is enabled, Jenkins will keep a full clone of the remote repository on the master. Then, if the job is built on a slave, it will keep a full clone of that on the slave (implemented by bundling and transferring changesets from the master over the remoting channel: the slave need have no public network connection). Finally, the job’s workspace will have a clone of the local cache, and that should be hardlinked since it is on the same disk. The main point of caching is to minimize traffic to the public repository. The disk consumption is larger. |
Got it, thanks for clarifying. |
You are right from a UI perspective it is not ideal, but neither is an additional drop down box I thinnk. |
I do not think you can detect whether something is a tag in advance. You would have to actually pull everything and search for that label. Putting this flag in the global configuration is just incorrect: some projects may be using tags and others branches. This has nothing to do with which Mercurial installation you use. Closing since this is a relatively major change and I probably need to do this work myself. |
if you want to build a tag it is necessary to pull the whole repository
JENKINS-14862