mirror of https://github.com/apache/maven.git
Fix classpath generation for Windows users
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@162568 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
f70e21faaa
commit
fbece66bf4
|
@ -86,13 +86,24 @@ public class Bootstrapper
|
|||
|
||||
StringBuffer libs = new StringBuffer();
|
||||
|
||||
String repoLocal = replace(downloader.getMavenRepoLocal().getPath(), "\\", "/");
|
||||
String classpathSeparator;
|
||||
if (repoLocal.indexOf(":") != -1) //Windows
|
||||
{
|
||||
classpathSeparator = ";";
|
||||
}
|
||||
else
|
||||
{
|
||||
classpathSeparator = ":";
|
||||
}
|
||||
|
||||
for ( Iterator i = dependencies.iterator(); i.hasNext(); )
|
||||
{
|
||||
Dependency d = (Dependency) i.next();
|
||||
|
||||
classPath.append( repoLocal + "/" + getArtifactPath( d, "/" ) + classpathSeparator );
|
||||
|
||||
classPath.append( downloader.getMavenRepoLocal() + "/" + getArtifactPath( d, "/" ) + ":" );
|
||||
|
||||
libs.append( downloader.getMavenRepoLocal() + "/" + getArtifactPath( d, "/" ) + "\n" );
|
||||
libs.append( repoLocal + "/" + getArtifactPath( d, "/" ) + "\n" );
|
||||
}
|
||||
|
||||
writeFile( "bootstrap.classpath", classPath.toString() );
|
||||
|
|
Loading…
Reference in New Issue