how to install
有些小伙伴想下载并自行install 进行研究, 你需要执行以下4个步骤:
1. 下载 feilong-platform
git clone https://github.com/venusdrogon/feilong-platform.git —depth 1
E:\work>git clone https://github.com/venusdrogon/feilong-platform.git --depth 1
Cloning into 'feilong-platform'...
remote: Counting objects: 9, done.
remote: Compressing objects: 100% (6/6), done.
remote: Total 9 (delta 0), reused 6 (delta 0), pack-reused 0
Unpacking objects: 100% (9/9), done.
2. install feilong-platform
mvn install -f feilong-platform/pom.xml
➜ test mvn install -f feilong-platform/pom.xml
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building feilong-platform 1.10.4-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-resources-plugin:3.0.2:resources (default-resources) @ parent ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /Users/feilong/workspace/test/feilong-platform/src/main/resources
[INFO]
[INFO] --- native2ascii-maven-plugin:1.0-beta-1:native2ascii (native2ascii) @ parent ---
[INFO]
[INFO] --- maven-resources-plugin:3.0.2:testResources (default-testResources) @ parent ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /Users/feilong/workspace/test/feilong-platform/src/test/resources
[INFO]
[INFO] >>> maven-source-plugin:3.0.1:jar (attach-sources) > generate-sources @ parent >>>
[INFO]
[INFO] <<< maven-source-plugin:3.0.1:jar (attach-sources) < generate-sources @ parent <<<
[INFO]
[INFO]
[INFO] --- maven-source-plugin:3.0.1:jar (attach-sources) @ parent ---
[INFO]
[INFO] --- maven-install-plugin:2.5.2:install (default-install) @ parent ---
[INFO] Installing /Users/feilong/workspace/test/feilong-platform/pom.xml to /Users/feilong/Development/repository/com/feilong/platform/parent/1.10.4-SNAPSHOT/parent-1.10.4-SNAPSHOT.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.255 s
[INFO] Finished at: 2017-07-08T02:16:29+08:00
[INFO] Final Memory: 11M/309M
[INFO] ------------------------------------------------------------------------
3. 下载 feilong-core
git clone https://github.com/venusdrogon/feilong-core.git —depth 1
➜ test git clone https://github.com/venusdrogon/feilong-core.git --depth 1
Cloning into 'feilong-core'...
remote: Counting objects: 492, done.
remote: Compressing objects: 100% (278/278), done.
remote: Total 492 (delta 311), reused 269 (delta 203), pack-reused 0
Receiving objects: 100% (492/492), 382.73 KiB | 72.00 KiB/s, done.
Resolving deltas: 100% (311/311), done.
4. install feilong-core
mvn install -f feilong-core/pom.xml
➜ test mvn install -f feilong-core/pom.xml
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building feilong-core 1.10.4-SNAPSHOT
[INFO] ------------------------------------------------------------------------
Downloading: https://raw.github.com/venusdrogon/feilong-platform/repository/com/feilong/test/feilong-common-test/1.10.1/feilong-common-test-1.10.1.pom
Downloaded: https://raw.github.com/venusdrogon/feilong-platform/repository/com/feilong/test/feilong-common-test/1.10.1/feilong-common-test-1.10.1.pom (5.1 kB at 1.3 kB/s)
Downloading: https://raw.github.com/venusdrogon/feilong-platform/repository/com/feilong/test/feilong-common-test/1.10.1/feilong-common-test-1.10.1.jar
Downloaded: https://raw.github.com/venusdrogon/feilong-platform/repository/com/feilong/test/feilong-common-test/1.10.1/feilong-common-test-1.10.1.jar (23 kB at 6.3 kB/s)
[INFO]
[INFO] --- jacoco-maven-plugin:0.7.9:prepare-agent (prepare-agent) @ feilong-core ---
[INFO] argLine set to -javaagent:/Users/feilong/Development/repository/org/jacoco/org.jacoco.agent/0.7.9/org.jacoco.agent-0.7.9-runtime.jar=destfile=/Users/feilong/workspace/test/feilong-core/target/jacoco.exec
[INFO]
[INFO] --- maven-resources-plugin:3.0.2:resources (default-resources) @ feilong-core ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 1 resource
[INFO]
[INFO] --- maven-compiler-plugin:3.6.1:compile (default-compile) @ feilong-core ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 71 source files to /Users/feilong/workspace/test/feilong-core/target/classes
[INFO] /Users/feilong/workspace/test/feilong-core/src/main/java/com/feilong/core/lang/StringUtil.java: 某些输入文件使用或覆盖了已过时的 API。
[INFO] /Users/feilong/workspace/test/feilong-core/src/main/java/com/feilong/core/lang/StringUtil.java: 有关详细信息, 请使用 -Xlint:deprecation 重新编译。
[INFO]
[INFO] --- native2ascii-maven-plugin:1.0-beta-1:native2ascii (native2ascii) @ feilong-core ---
[INFO] Includes: [classes\**/*.properties, test-classes\**/*.properties]
[INFO] Excludes: []
[INFO]
[INFO] --- maven-resources-plugin:3.0.2:testResources (default-testResources) @ feilong-core ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 6 resources
[INFO]
[INFO] --- maven-compiler-plugin:3.6.1:testCompile (default-testCompile) @ feilong-core ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 332 source files to /Users/feilong/workspace/test/feilong-core/target/test-classes
[INFO] /Users/feilong/workspace/test/feilong-core/src/test/java/com/feilong/core/util/sortutiltest/SortArrayTest.java: 某些输入文件使用或覆盖了已过时的 API。
[INFO] /Users/feilong/workspace/test/feilong-core/src/test/java/com/feilong/core/util/sortutiltest/SortArrayTest.java: 有关详细信息, 请使用 -Xlint:deprecation 重新编译。
[INFO] /Users/feilong/workspace/test/feilong-core/src/test/java/com/feilong/core/util/collectionsutiltest/GroupWithTransformerAndPredicateTest.java: 某些输入文件使用了未经检查或不安全的操作。
[INFO] /Users/feilong/workspace/test/feilong-core/src/test/java/com/feilong/core/util/collectionsutiltest/GroupWithTransformerAndPredicateTest.java: 有关详细信息, 请使用 -Xlint:unchecked 重新编译。
[INFO]
[INFO] --- maven-surefire-plugin:2.20:test (default-test) @ feilong-core ---
[INFO]
[INFO] -------------------------------------------------------
[INFO] T E S T S
[INFO] -------------------------------------------------------
[INFO] Running com.feilong.FeiLongSuiteTests
20:20 WARN (DateTimeConverter.java:471) [toDate()] DateConverter does not support default String to 'Date' conversion.
20:20 WARN (DateTimeConverter.java:472) [toDate()] (N.B. Re-configure Converter or use alternative implementation)
20:20 INFO (URLUtil.java:150) [toURL()] [new URL("E:\test")] exception,cause by :[unknown protocol: e],will try call [toFileURL("E:\test")]
20:20 DEBUG (GetUnionUrlTest.java:45) [testGetUnionUrl1()] file:/Users/feilong/workspace/test/feilong-core/sanguo
20:20 INFO (URLUtil.java:150) [toURL()] [new URL("C:\Users\feilong\feilong\train\新员工\warmReminder\20160704141057.html")] exception,cause by :[unknown protocol: c],will try call [toFileURL("C:\Users\feilong\feilong\train\新员工\warmReminder\20160704141057.html")]
20:20 DEBUG (ToURLTest.java:41) [testToURL()] file:/Users/feilong/workspace/test/feilong-core/C:%5CUsers%5Cfeilong%5Cfeilong%5Ctrain%5C新员工%5CwarmReminder%5C20160704141057.html
20:21 WARN (ResourceBundleUtil.java:151) [getValue()] resourceBundle:[java.util.PropertyResourceBundle@118ffcfd] don't containsKey:[wo_bu_cun_zai]
20:21 WARN (ResourceBundleUtil.java:151) [getValue()] resourceBundle:[java.util.PropertyResourceBundle@36c2b646] don't containsKey:[wo_bu_cun_zai]
[INFO] Tests run: 1513, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.24 s - in com.feilong.FeiLongSuiteTests
[INFO]
[INFO] Results:
[INFO]
[INFO] Tests run: 1513, Failures: 0, Errors: 0, Skipped: 0
[INFO]
[INFO]
[INFO] --- jacoco-maven-plugin:0.7.9:report (post-unit-test) @ feilong-core ---
[INFO] Loading execution data file /Users/feilong/workspace/test/feilong-core/target/jacoco.exec
[INFO] Analyzed bundle 'feilong-core' with 62 classes
[INFO]
[INFO] --- jacoco-maven-plugin:0.7.9:report (report) @ feilong-core ---
[INFO] Loading execution data file /Users/feilong/workspace/test/feilong-core/target/jacoco.exec
[INFO] Analyzed bundle 'feilong-core' with 62 classes
[INFO]
[INFO] --- maven-jar-plugin:2.6:jar (default-jar) @ feilong-core ---
[INFO] Building jar: /Users/feilong/workspace/test/feilong-core/target/feilong-core-1.10.4-SNAPSHOT.jar
[INFO]
[INFO] --- maven-jar-plugin:2.6:test-jar (default) @ feilong-core ---
[INFO] Building jar: /Users/feilong/workspace/test/feilong-core/target/feilong-core-1.10.4-SNAPSHOT-tests.jar
[INFO]
[INFO] >>> maven-source-plugin:3.0.1:jar (attach-sources) > generate-sources @ feilong-core >>>
[INFO]
[INFO] --- jacoco-maven-plugin:0.7.9:prepare-agent (prepare-agent) @ feilong-core ---
[INFO] argLine set to -javaagent:/Users/feilong/Development/repository/org/jacoco/org.jacoco.agent/0.7.9/org.jacoco.agent-0.7.9-runtime.jar=destfile=/Users/feilong/workspace/test/feilong-core/target/jacoco.exec
[INFO]
[INFO] <<< maven-source-plugin:3.0.1:jar (attach-sources) < generate-sources @ feilong-core <<<
[INFO]
[INFO]
[INFO] --- maven-source-plugin:3.0.1:jar (attach-sources) @ feilong-core ---
[INFO] Building jar: /Users/feilong/workspace/test/feilong-core/target/feilong-core-1.10.4-SNAPSHOT-sources.jar
[INFO]
[INFO] --- maven-install-plugin:2.5.2:install (default-install) @ feilong-core ---
[INFO] Installing /Users/feilong/workspace/test/feilong-core/target/feilong-core-1.10.4-SNAPSHOT.jar to /Users/feilong/Development/repository/com/feilong/platform/feilong-core/1.10.4-SNAPSHOT/feilong-core-1.10.4-SNAPSHOT.jar
[INFO] Installing /Users/feilong/workspace/test/feilong-core/pom.xml to /Users/feilong/Development/repository/com/feilong/platform/feilong-core/1.10.4-SNAPSHOT/feilong-core-1.10.4-SNAPSHOT.pom
[INFO] Installing /Users/feilong/workspace/test/feilong-core/target/feilong-core-1.10.4-SNAPSHOT-tests.jar to /Users/feilong/Development/repository/com/feilong/platform/feilong-core/1.10.4-SNAPSHOT/feilong-core-1.10.4-SNAPSHOT-tests.jar
[INFO] Installing /Users/feilong/workspace/test/feilong-core/target/feilong-core-1.10.4-SNAPSHOT-sources.jar to /Users/feilong/Development/repository/com/feilong/platform/feilong-core/1.10.4-SNAPSHOT/feilong-core-1.10.4-SNAPSHOT-sources.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 26.079 s
[INFO] Finished at: 2017-07-08T02:20:23+08:00
[INFO] Final Memory: 35M/591M
[INFO] ------------------------------------------------------------------------
5. settings.xml 镜像
如果你配置了镜像, 比如 aliyun
<mirrors>
<mirror>
<mirrorOf>*</mirrorOf>
<id>alimaven</id>
<name>aliyun maven</name>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
</mirror>
</mirrors>
那么在执行 mvn install -f feilong-taglib/pom.xml
会出错, 以下是大致的错误信息
➜ test mvn install -f feilong-core/pom.xml
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building feilong-core 1.10.4-SNAPSHOT
[INFO] ------------------------------------------------------------------------
Downloading: http://maven.aliyun.com/nexus/content/groups/public/com/feilong/test/feilong-common-test/1.10.1/feilong-common-test-1.10.1.pom
[WARNING] The POM for com.feilong.test:feilong-common-test:jar:1.10.1 is missing, no dependency information available
Downloading: http://maven.aliyun.com/nexus/content/groups/public/com/feilong/test/feilong-common-test/1.10.1/feilong-common-test-1.10.1.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4.250 s
[INFO] Finished at: 2017-07-08T02:17:58+08:00
[INFO] Final Memory: 11M/245M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project feilong-core: Could not resolve dependencies for project com.feilong.platform:feilong-core:jar:1.10.4-SNAPSHOT: Could not find artifact com.feilong.test:feilong-common-test:jar:1.10.1 in alimaven (http://maven.aliyun.com/nexus/content/groups/public/) -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException
此时你需要修改下镜像的 mirrorOf
,让镜像排除 feilong-platform-repository
仓库
<mirror>
<mirrorOf>*,!feilong-platform-repository</mirrorOf>
<id>alimaven</id>
<name>aliyun maven</name>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
</mirror>
更多关于 maven mirrorOf
,可以参考 http://maven.apache.org/guides/mini/guide-mirror-settings.html
6.帮助
如果仍旧有问题,您可以
|QQ 群 243306798
:————-|
—完
当前内容版权归 feilong-core 或其关联方所有,如需对内容或内容相关联开源项目进行关注与资助,请访问 feilong-core .