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
sbt unnecessarily copies local dependencies to staging #2202
Comments
This allows using a project reference that points to a readonly directory. The use case for this is having sbt plugin projects on a network share (readonly) that you can just point to. The plugin projects get copied and built automatically, just like a git project reference gets cloned and built. This will ease plugin imcompatibilies between minor sbt versions, avoiding to have to cross build plugins against all compatible sbt versions.
I don't understand, can you elaborate? What's the problem you're having? |
Several projects in a read-only source tree with target set to writable directories:
project{a,b,c} depend on commonproject. When projecta is built, the referenced code determines that |
So |
Exactly, all the build directories are, src aren't. (the use-case is developing with Docker: source r/o mounted from the host, build/run in the container). |
OK, I agree that it should not copy the project if |
Actually, having thought a bit more, this won't work in every situation. For example, I have projects that generate source files somewhere under the |
That's pretty weird I think. By that logic you could also copy But anyway, I see it would be a regression. I will find a way to change this only for myself. |
@duboisf So now that we are also moving development (not just test/prod) to a read-only source tree, this is even a bigger problem: Changes to source files are not detected unless you manually delete staging before every compile. |
SBT copies local dependencies to a staging directory if their source directory is not writable. I do not think this should be required if the targetDirectory of those dependencies is outside the source directory.
Shouldn't the targetDirectory be checked for writability instead?
The text was updated successfully, but these errors were encountered: