-
New Feature
-
Resolution: Unresolved
-
Major
-
None
There should be a checkbox, when building from a workspace, to restore the checkout to its pristine state.
I know you can do this with a build definition, but I cannot use build definitions[1] in my case and have to use workspaces.
For example, the git scm plugin has this checkbox.
See https://jazz.net/forum/questions/141370/scm-how-to-restore-a-workspace-to-pristine
[1] I can't use build definitions because I cannot create, update, and destroy them in a programatic fashion. Manually creating 100s of build definitions is too boring.
So Build definition's delete before loading is what you are doing now if I understand your forum question. Basically deleting the entire sandbox directory and then loading. I got from your forum post that this is too heavy.
Sounds to me like you want the sandbox to hold exclusively just the contents of the workspace being built (i.e. some other build step can't populate the sandbox directory with other contents like scripts, tools, etc.). As well when the load takes place, it replaces the contents on disk with whats in the repository. If there are files/folders/links that are ignored & not in the repository, they should be deleted from disk (often build artifacts like bin directory, .class files etc. are marked as ignored and not in the repo, so they should be deleted to ensure a full build). Currently our load operation will leave those ignored items on disk.
Just want to be sure I understand your definition of "pristine".