Tag Archive for maven

eclipse/sts maven run problem

ha a hiba:

-Dmaven.multiModuleProjectDirectory system propery is not set Check $M2_HOME environment variable and mvn script match.

 

megoldás:

Window–> Preference –> Java –> Installed JREs –> Edit In the edit Default VM arguments you need to put If you already set the maven home. -Dmaven.multiModuleProjectDirectory=M2_HOME (For Windows machine) -Dmaven.multiModuleProjectDirectory=$M2_HOME (For Mac OS X)

 

src:

http://stackoverflow.com/questions/29285148/eclipse-error-setting-up-maven-project-for-class-exercise-check-m2-home-enviro

Eclipse Maven problem

Window-> Preference -> Java -> Installed JREs -> Edit

In the edit Default VM arguments you need to put

If you already set the maven home.

-Dmaven.multiModuleProjectDirectory=$M2_HOME

 

Maven install

mvn install:install-file -Dfile=mscpdf.jar -DgroupId=microsec.mscpdf -DartifactId=mscpdf -Dversion=3.2.7.10 -Dpackaging=jar -DgeneratePom=true

vagy:

mvn deploy:deploy-file -DgroupId=microsec.com.itextpdf -DartifactId=itext -Dversion=3.2.7.10 -Dpackaging=jar -Dfile=iText.jar -DrepositoryId=dev-releases -Durl=http://housemaster:8082/dev-releases

 

Java target definiálása Maven projektben

POM-ba tenni:

<plugin>
	<groupId>org.apache.maven.plugins</groupId>
	<artifactId>maven-compiler-plugin</artifactId>
	<configuration>
		<source>1.8</source>
		<target>1.8</target>
		<showDeprecation>true</showDeprecation>
		<showWarnings>true</showWarnings>
		<executable>${env.JAVA_HOME_8}/bin/javac</executable>
		<fork>true</fork>
	</configuration>
</plugin>

FONTOS: JAVA_HOME_8 környezeti változó mutasson a JDK8-ra.

m2-subclipse telepítése subclipse >=1.08 verziószámból

Ha az alábbi hibát kapjuk az eclipse-ben telepítéskor (Preferences->MAven->Discovery->

Cannot complete the install because one or more required items could not be found. Software being installed: Maven SCM handler for Subclipse 0.13.0.201303011221 (org.sonatype.m2e.subclipse.feature.feature.group 0.13.0.201303011221) Missing requirement: Maven SCM Handler for Subclipse 0.13.0.201303011221 (org.sonatype.m2e.subclipse 0.13.0.201303011221) requires ‘bundle org.tigris.subversion.subclipse.core [1.6.0,1.9.0)’ but it could not be found Cannot satisfy dependency: From: Maven SCM handler for Subclipse 0.13.0.201303011221 (org.sonatype.m2e.subclipse.feature.feature.group 0.13.0.201303011221) To: org.sonatype.m2e.subclipse [0.13.0.201303011221]

ha érezzük az erőt:

chackout and build

git clone https://github.com/tesla/m2eclipse-subclipse
cd m2eclipse-subclipse
mvn install

Majd install:

Help->New Software-> local es a < a kichckoutolt repo helye> /org.sonatype.m2e.subclipse.feature/target/site/

vagy a zip: m2-subclipse

vagy eclipse update site: https://ronhks.hu/eclipse/m2-subclipse/update-site