清理依赖
mvn clean dependency:copy-dependencies package
打包
mvn package
mvn clean package
创建
mvn archetype:create -DgroupId=com.adosoft -DartifactId=ado-modules
mvn archetype:create -DgroupId=com.adosoft -DartifactId=ado-core
mvn archetype:create -DgroupId=com.adosoft -DartifactId=ado-flow
mvn archetype:create -DgroupId=com.adosoft -DartifactId=ado-work
mvn archetype:create -DgroupId=com.adosoft -DartifactId=faint-work
mvn archetype:create \
-DarchetypeGroupId=org.apache.maven.archetypes \
-DarchetypeArtifactId=maven-archetype-site \
-DgroupId=com.mycompany.app \
-DartifactId=my-app-site
mvn archetype:create -DarchetypeGroupId=org.apache.maven.archetypes -DarchetypeArtifactId=maven-archetype-webapp -DgroupId=com.mochasoft.mgs.hi -DartifactId=uniwork
mvn archetype:create -DarchetypeGroupId=org.apache.maven.archetypes -DarchetypeArtifactId=maven-archetype-webapp -DgroupId=com.mochasoft.mgs.hi -DartifactId=mochauniwork
mvn archetype:create -DarchetypeGroupId=org.apache.maven.archetypes -DgroupId=com.mochasoft.mgs.hi -DartifactId=uniwork
mvn archetype:create -DarchetypeGroupId=org.springframework.ws -DarchetypeArtifactId=spring-ws-archetype -DarchetypeVersion=1.0.1 -DgroupId=com.mochasoft.hi -DartifactId=uniwork
mvn install:install-file -DgroupId=jdbc -DartifactId=oracle -Dversion=10g -Dpackaging=jar -Dfile=D:/classes12.jar
mvn install:install-file -DgroupId=opensymphony -DartifactId=osworkflow -Dversion=2.8.0 -Dpackaging=jar -Dfile=E:\opensource\workflow\osworkflow-2.8.0\osworkflow-2.8.0.jar
mvn install:install-file -DgroupId=jdbc -DartifactId=oracle -Dversion=10g -Dpackaging=jar -Dfile=D:/ojdbc14.jar
mvn scm:cvs|pserver|dongyl@localhost|C:/Program Files/cvsnt/repositories|module_name
mvn scm:cvs|pserver|dongyl|dongyl@localhost|D:/version/cvsroot/uniwork
mvn plugin:download -Dmaven.repo.remote=http://maven-plugins.sourceforge.net/maven/ -DgroupId=maven-plugins -DartifactId=maven-was6-plugin
//格式化代码
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>jalopy-maven-plugin</artifactId>
<version>1.0-alpha-1</version>
</plugin>
mvn jalopy:format
mvn archetype:create -DgroupId=com.mochasoft.portal -DartifactId=portlet -DarchetypeArtifactId=maven-archetype-portlet
pluto
在~/.m2/settings.xml中添加如下内容才可使用以下命令
<settings>
.....
<pluginGroups>
<pluginGroup>org.apache.pluto</pluginGroup>
</pluginGroups>
.....
</settings>
mvn pluto:install -DinstallDir=D:\installed\apache-tomcat-6.0.14
设置tomcat
1.To be able to use application-scoped PortletSession attributes in Pluto, modify the Connector element for port 8080 in <TOMCAT_HOME>/conf/server.xml by adding the following attribute and value: emptySessionPath="true".
2.The Pluto Testsuite portlet application needs the role 'pluto' to run the Security Mapping Test. So before starting tomcat, you should edit <TOMCAT_HOME>/conf/tomcat-users.xml, add the role 'pluto', and add a user in that role. The simplest way to do this is to edit add the 'pluto' role to the 'tomcat' user's record. Here is a sample tomcat-users.xml file:
3.使用http://localhost:8080/pluto/portal tomcat/tomcat
多个项目合作
在父项目pom.xml中添加以下内容:
<modules>
<module>guide-ide-eclipse-site</module>
<module>guide-ide-eclipse-core</module>
<module>guide-ide-eclipse-module1</module>
</modules>
在子项目pom.xml中添加以下内容:
<parent>
<groupId>guide.ide.eclipse</groupId>
<artifactId>guide-ide-eclipse</artifactId>
<version>1.0-SNAPSHOT</version>
</parent>
Add dependency from module1 to the core-module:
<dependency>
<groupId>guide.ide.eclipse.core</groupId>
<artifactId>guide-ide-eclipse-core</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
Install the project in your local repository and generate the Eclipse files:
mvn install
mvn eclipse:eclipse
Check in your project using the Eclipse team support (select from the context menu Team > Share Project). Note: Do not check in the generated Eclipse files. If you use CVS you should have a .cvsignore-file with the following entries for each module:
target
.classpath
.project
.wtpmodules
Even the parent project should have this .cvsignore-file. Eclipse will automatically generate a new simple .project-file when you check out the project from the repository.
Add M2_REPO to workspace:
mvn -Declipse.workspace=D:\workspaces\ eclipse:add-maven-repo
mvn -Dmessage="hello" -Dmaven.scm.provider.cvs.implementation=cvs_native scm:checkin
mvn archetype:create -DarchetypeGroupId=org.apache.maven.archetypes -DarchetypeArtifactId=maven-archetype-webapp -DgroupId=com.nagor -DartifactId=agor-flow
mvn clean dependency:copy-dependencies package
打包
mvn package
mvn clean package
创建
mvn archetype:create -DgroupId=com.adosoft -DartifactId=ado-modules
mvn archetype:create -DgroupId=com.adosoft -DartifactId=ado-core
mvn archetype:create -DgroupId=com.adosoft -DartifactId=ado-flow
mvn archetype:create -DgroupId=com.adosoft -DartifactId=ado-work
mvn archetype:create -DgroupId=com.adosoft -DartifactId=faint-work
mvn archetype:create \
-DarchetypeGroupId=org.apache.maven.archetypes \
-DarchetypeArtifactId=maven-archetype-site \
-DgroupId=com.mycompany.app \
-DartifactId=my-app-site
mvn archetype:create -DarchetypeGroupId=org.apache.maven.archetypes -DarchetypeArtifactId=maven-archetype-webapp -DgroupId=com.mochasoft.mgs.hi -DartifactId=uniwork
mvn archetype:create -DarchetypeGroupId=org.apache.maven.archetypes -DarchetypeArtifactId=maven-archetype-webapp -DgroupId=com.mochasoft.mgs.hi -DartifactId=mochauniwork
mvn archetype:create -DarchetypeGroupId=org.apache.maven.archetypes -DgroupId=com.mochasoft.mgs.hi -DartifactId=uniwork
mvn archetype:create -DarchetypeGroupId=org.springframework.ws -DarchetypeArtifactId=spring-ws-archetype -DarchetypeVersion=1.0.1 -DgroupId=com.mochasoft.hi -DartifactId=uniwork
mvn install:install-file -DgroupId=jdbc -DartifactId=oracle -Dversion=10g -Dpackaging=jar -Dfile=D:/classes12.jar
mvn install:install-file -DgroupId=opensymphony -DartifactId=osworkflow -Dversion=2.8.0 -Dpackaging=jar -Dfile=E:\opensource\workflow\osworkflow-2.8.0\osworkflow-2.8.0.jar
mvn install:install-file -DgroupId=jdbc -DartifactId=oracle -Dversion=10g -Dpackaging=jar -Dfile=D:/ojdbc14.jar
mvn scm:cvs|pserver|dongyl@localhost|C:/Program Files/cvsnt/repositories|module_name
mvn scm:cvs|pserver|dongyl|dongyl@localhost|D:/version/cvsroot/uniwork
mvn plugin:download -Dmaven.repo.remote=http://maven-plugins.sourceforge.net/maven/ -DgroupId=maven-plugins -DartifactId=maven-was6-plugin
//格式化代码
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>jalopy-maven-plugin</artifactId>
<version>1.0-alpha-1</version>
</plugin>
mvn jalopy:format
mvn archetype:create -DgroupId=com.mochasoft.portal -DartifactId=portlet -DarchetypeArtifactId=maven-archetype-portlet
pluto
在~/.m2/settings.xml中添加如下内容才可使用以下命令
<settings>
.....
<pluginGroups>
<pluginGroup>org.apache.pluto</pluginGroup>
</pluginGroups>
.....
</settings>
mvn pluto:install -DinstallDir=D:\installed\apache-tomcat-6.0.14
设置tomcat
1.To be able to use application-scoped PortletSession attributes in Pluto, modify the Connector element for port 8080 in <TOMCAT_HOME>/conf/server.xml by adding the following attribute and value: emptySessionPath="true".
2.The Pluto Testsuite portlet application needs the role 'pluto' to run the Security Mapping Test. So before starting tomcat, you should edit <TOMCAT_HOME>/conf/tomcat-users.xml, add the role 'pluto', and add a user in that role. The simplest way to do this is to edit add the 'pluto' role to the 'tomcat' user's record. Here is a sample tomcat-users.xml file:
3.使用http://localhost:8080/pluto/portal tomcat/tomcat
多个项目合作
在父项目pom.xml中添加以下内容:
<modules>
<module>guide-ide-eclipse-site</module>
<module>guide-ide-eclipse-core</module>
<module>guide-ide-eclipse-module1</module>
</modules>
在子项目pom.xml中添加以下内容:
<parent>
<groupId>guide.ide.eclipse</groupId>
<artifactId>guide-ide-eclipse</artifactId>
<version>1.0-SNAPSHOT</version>
</parent>
Add dependency from module1 to the core-module:
<dependency>
<groupId>guide.ide.eclipse.core</groupId>
<artifactId>guide-ide-eclipse-core</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
Install the project in your local repository and generate the Eclipse files:
mvn install
mvn eclipse:eclipse
Check in your project using the Eclipse team support (select from the context menu Team > Share Project). Note: Do not check in the generated Eclipse files. If you use CVS you should have a .cvsignore-file with the following entries for each module:
target
.classpath
.project
.wtpmodules
Even the parent project should have this .cvsignore-file. Eclipse will automatically generate a new simple .project-file when you check out the project from the repository.
Add M2_REPO to workspace:
mvn -Declipse.workspace=D:\workspaces\ eclipse:add-maven-repo
mvn -Dmessage="hello" -Dmaven.scm.provider.cvs.implementation=cvs_native scm:checkin
mvn archetype:create -DarchetypeGroupId=org.apache.maven.archetypes -DarchetypeArtifactId=maven-archetype-webapp -DgroupId=com.nagor -DartifactId=agor-flow