I am using TFS 2010 and the Maven build extension. I have many working builds in place. I have a new one, however, that compiles source code but then fails when it tries to create a jar file. I have googled my fingers to the bone. Does anyone have a suggestion? BTW, I can run a Maven build manually on the build server on top of the source pulled over by TFS, and the manual build works fine. Also, the jar that is read-only is created by the Maven build. (And it is read-only when built with TFS and not read-only when built manually.)
[INFO] Scanning for projects... [INFO] ------------------------------------------------------------------------ [INFO] Building Services-Core [INFO] task-segment: [install] [INFO] ------------------------------------------------------------------------ [INFO] [resources:resources {execution: default-resources}] [INFO] Using 'UTF-8' encoding to copy filtered resources. [INFO] Copying 2 resources [INFO] [compiler:compile {execution: default-compile}] [INFO] Compiling 23 source files to C:\Builds\7\Services-Core\test4\Sources\web\WEB-INF\classes [INFO] [resources:testResources {execution: default-testResources}] [INFO] Using 'UTF-8' encoding to copy filtered resources. [INFO] Copying 10 resources [INFO] [compiler:testCompile {execution: default-testCompile}] [INFO] Not compiling test sources [INFO] [surefire:test {execution: default-test}] [INFO] Tests are skipped. [INFO] [jar:jar {execution: default-jar}] [INFO] ------------------------------------------------------------------------ [ERROR] BUILD ERROR [INFO] ------------------------------------------------------------------------ [INFO] Error assembling JAR Embedded error: C:\Builds\7\Services-Core\test4\Sources\target\Services-Core-1.0.0.jar is read-only. [INFO] ------------------------------------------------------------------------ [INFO] For more information, run Maven with the -e switch [INFO] ------------------------------------------------------------------------ [INFO] Total time: 3 seconds [INFO] Finished at: Wed Feb 08 23:21:35 GMT 2012 [INFO] Final Memory: 18M/45M [INFO] ------------------------------------------------------------------------