{"id":5891,"date":"2024-04-16T13:45:10","date_gmt":"2024-04-16T05:45:10","guid":{"rendered":"http:\/\/zyg.luchers.cn\/?p=5891"},"modified":"2024-04-16T13:45:10","modified_gmt":"2024-04-16T05:45:10","slug":"%e7%ac%ac%e4%ba%94%e7%ab%a0%e3%80%81%e5%85%b6%e4%bb%96%e6%a0%b8%e5%bf%83%e6%a6%82%e5%bf%b5","status":"publish","type":"post","link":"http:\/\/zyg.luchers.cn\/index.php\/2024\/04\/16\/%e7%ac%ac%e4%ba%94%e7%ab%a0%e3%80%81%e5%85%b6%e4%bb%96%e6%a0%b8%e5%bf%83%e6%a6%82%e5%bf%b5\/","title":{"rendered":"\u7b2c\u4e94\u7ae0\u3001\u5176\u4ed6\u6838\u5fc3\u6982\u5ff5"},"content":{"rendered":"<h1>\u7b2c\u4e94\u7ae0\u3001\u5176\u4ed6\u6838\u5fc3\u6982\u5ff5<\/h1>\n<h2>1\u3001\u751f\u547d\u5468\u671f<\/h2>\n<h3>1\u3001\u4f5c\u7528<\/h3>\n<p>1\u3001\u4e3a\u4e86\u8ba9\u6784\u5efa\u8fc7\u7a0b\u81ea\u52a8\u5316\u5b8c\u6210\uff0cMavne\u8bbe\u5b9a\u4e863\u4e2a\u751f\u547d\u5468\u671f\uff0c\u6bcf\u4e2a\u73af\u8282\u5bf9\u5e94\u6784\u5efa\u8fc7\u7a0b\u4e2d\u7684\u4e00\u4e2a\u64cd\u4f5c<\/p>\n<h3>2\u3001\u4e09\u4e2a\u751f\u547d\u5468\u671f<\/h3>\n<table>\n<thead>\n<tr>\n<th>\u751f\u547d\u5468\u671f\u540d\u79f0<\/th>\n<th>\u4f5c\u7528<\/th>\n<th>\u5404\u4e2a\u73af\u8282<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>Clean<\/td>\n<td>\u6e05\u7406\u64cd\u4f5c\u76f8\u5173<\/td>\n<td>pre-clean<br \/>clean<br \/>post-clean<\/td>\n<\/tr>\n<tr>\n<td>Site<\/td>\n<td>\u751f\u6210\u7ad9\u70b9\u76f8\u5173<\/td>\n<td>pre-site<br \/>site<br \/>post-site<br \/>deploy-site<\/td>\n<\/tr>\n<tr>\n<td>Default<\/td>\n<td>\u4e3b\u8981\u6784\u5efa\u8fc7\u7a0b<\/td>\n<td>validate\uff1a\u68c0\u67e5maven\u7684\u7ed3\u6784<br \/>generate-sources\uff1a\u7f16\u8bd1\u6e90\u7801<br \/>process-sources<br \/>generate-resources<br \/>process-resources \u590d\u5236\u5e76\u5904\u7406\u8d44\u6e90\u6587\u4ef6\uff0c\u81f3\u76ee\u6807\u76ee\u5f55\uff0c\u51c6\u5907\u6253\u5305\u3002<br \/>compile \u7f16\u8bd1\u9879\u76ee main \u76ee\u5f55\u4e0b\u7684\u6e90\u4ee3\u7801\u3002<br \/>process-classes<br \/>generate-test-sources<br \/>process-test-sources<br \/>generate-test-resources<br \/>process-test-resources \u590d\u5236\u5e76\u5904\u7406\u8d44\u6e90\u6587\u4ef6\uff0c\u81f3\u76ee\u6807\u6d4b\u8bd5\u76ee\u5f55\u3002<br \/>test-compile \u7f16\u8bd1\u6d4b\u8bd5\u6e90\u4ee3\u7801\u3002<br \/>process-test-classes<br \/>test \u4f7f\u7528\u5408\u9002\u7684\u5355\u5143\u6d4b\u8bd5\u6846\u67b6\u8fd0\u884c\u6d4b\u8bd5\u3002\u8fd9\u4e9b\u6d4b\u8bd5\u4ee3\u7801\u4e0d\u4f1a\u88ab\u6253\u5305\u6216\u90e8\u7f72\u3002<br \/>prepare-package\uff1a\u51c6\u5907\u6253\u5305<br \/>package \u63a5\u53d7\u7f16\u8bd1\u597d\u7684\u4ee3\u7801\uff0c\u6253\u5305\u6210\u53ef\u53d1\u5e03\u7684\u683c\u5f0f\uff0c\u5982JAR\u3002<br \/>pre-integration-test<br \/>integration-test<br \/>post-integration-test<br \/>verify<br \/>install\u5c06\u5305\u5b89\u88c5\u81f3\u672c\u5730\u4ed3\u5e93\uff0c\u4ee5\u8ba9\u5176\u5b83\u9879\u76ee\u4f9d\u8d56\u3002<br \/>deploy\u5c06\u6700\u7ec8\u7684\u5305\u590d\u5236\u5230\u8fdc\u7a0b\u7684\u4ed3\u5e93\uff0c\u4ee5\u8ba9\u5176\u5b83\u5f00\u53d1\u4eba\u5458\u5171\u4eab\uff1b\u6216\u8005\u90e8\u7f72\u5230\u670d\u52a1\u5668\u4e0a\u8fd0\u884c\uff08\u9700\u501f\u52a9\u63d2\u4ef6\uff0c\u4f8b\u5982\uff1acargo\uff09\u3002<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h2>2\u3001\u63d2\u4ef6\u548c\u76ee\u6807<\/h2>\n<h3>1\u3001\u63d2\u4ef6<\/h3>\n<p>1\uff1b\u6982\u5ff5\uff1aMaven\u7684\u6838\u5fc3\u4ec5\u4ec5\u8d1f\u8d23\u5b8f\u89c2\u8c03\u63a7\uff0c\u4e0d\u505a\u5177\u4f53\u5de5\u4f5c\u3002<\/p>\n<p>2\u3001\u5177\u4f53\u5de5\u4f5c\u90fd\u662fMaven\u63d2\u4ef6\u5b8c\u6210\u7684<\/p>\n<p>3\u3001\u4f8b\u5982\uff1a\u7f16\u8bd1\u662f\u7531maven-compiler-plugin-3.1.jar\u63d2\u4ef6\u6765\u6267\u884c<\/p>\n<h3>2\u3001\u76ee\u6807<\/h3>\n<p>1\u3001\u76f8\u5f53\u4e8e\u63d2\u4ef6\u7684\u529f\u80fd\uff0c\u4e00\u4e2a\u76ee\u6807\u5c31\u662f\u63d2\u4ef6\u7684\u529f\u80fd<\/p>\n<p>2\u3001\u4e00\u4e2a\u63d2\u4ef6\u53ef\u4ee5\u5bf9\u5e94\u591a\u4e2a\u76ee\u6807\uff0c\u6bcf\u4e00\u4e2a\u76ee\u6807\u90fd\u548c\u751f\u547d\u5468\u671f\u7684\u67d0\u4e2a\u73af\u8282\u5bf9\u5e94<\/p>\n<p>3\u3001Default \u751f\u547d\u5468\u671f\u4e2d\u6709 compile \u548c test-compile \u4e24\u4e2a\u548c\u7f16\u8bd1\u76f8\u5173\u7684\u73af\u8282\uff0c\u8fd9\u4e24\u4e2a\u73af\u8282\u5bf9\u5e94 compile \u548c test-compile \u4e24\u4e2a\u76ee\u6807\uff0c\u800c\u8fd9\u4e24\u4e2a\u76ee\u6807\u90fd\u662f\u7531 maven-compiler-plugin-3.1.jar \u63d2\u4ef6\u6765\u6267\u884c\u7684\u3002<\/p>\n<h2>3\u3001\u4ed3\u5e93<\/h2>\n<h3>1\u3001\u672c\u5730\u4ed3\u5e93<\/h3>\n<p>1\u3001\u5728\u5f53\u524d\u7535\u8111\u4e0a\uff0c\u4e3a\u7535\u8111\u6240\u6709Maven\u5de5\u7a0b\u670d\u52a1<\/p>\n<h3>2\u3001\u8fdc\u7a0b\u4ed3\u5e93<\/h3>\n<p>1\u3001\u9700\u8981\u8054\u7f51<\/p>\n<p>2\u3001\u5c40\u57df\u7f51\uff1a\u81ea\u5df1\u642d\u7684Maven\u79c1\u670d\uff0c\u4f8b\u5982\u4f7f\u7528Nexus\u6280\u672f<\/p>\n<p>3\u3001\u4e2d\u592e\u4ed3\u5e93<\/p>\n<p>4\u3001\u955c\u50cf\u4ed3\u5e93\uff1a\u5185\u5bb9\u548c\u4e2d\u592e\u4ed3\u5e93\u4e00\u6837 \uff0c\u53ef\u4ee5\u4e3a\u4e2d\u592e\u4ed3\u5e93\u5206\u62c5\u8d1f\u8f7d\u548c\u63d0\u9ad8\u4e0b\u8f7d\u901f\u5ea6<\/p>\n<p>5\u3001\u6ce8\u610f\uff1a\u4e0d\u8981\u539f\u751f\u4ed3\u5e93\u548c\u963f\u91cc\u4ed3\u5e93\u4e00\u8d77\u6df7\u7528\uff0c\u4f1a\u5bfc\u81f4jar\u5305\u4e0d\u7eaf\uff0c\u5f7c\u6b64\u51b2\u7a81<\/p>\n<p>6\u3001\u4e13\u95e8\u641c\u7d22Maven\u4f9d\u8d56\u4fe1\u606f\u7684\u7f51\u7ad9\uff1a<a href=\"https:\/\/mvnrespository.com\">https:\/\/mvnrespository.com<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u7b2c\u4e94\u7ae0\u3001\u5176\u4ed6\u6838\u5fc3\u6982\u5ff5 1\u3001\u751f\u547d\u5468\u671f 1\u3001\u4f5c\u7528 1\u3001\u4e3a\u4e86\u8ba9\u6784\u5efa\u8fc7\u7a0b\u81ea\u52a8\u5316\u5b8c\u6210\uff0cMavne\u8bbe\u5b9a\u4e863\u4e2a\u751f\u547d\u5468\u671f\uff0c\u6bcf\u4e2a [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[24],"tags":[],"class_list":["post-5891","post","type-post","status-publish","format-standard","hentry","category-maven"],"_links":{"self":[{"href":"http:\/\/zyg.luchers.cn\/index.php\/wp-json\/wp\/v2\/posts\/5891","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/zyg.luchers.cn\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/zyg.luchers.cn\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/zyg.luchers.cn\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/zyg.luchers.cn\/index.php\/wp-json\/wp\/v2\/comments?post=5891"}],"version-history":[{"count":1,"href":"http:\/\/zyg.luchers.cn\/index.php\/wp-json\/wp\/v2\/posts\/5891\/revisions"}],"predecessor-version":[{"id":5892,"href":"http:\/\/zyg.luchers.cn\/index.php\/wp-json\/wp\/v2\/posts\/5891\/revisions\/5892"}],"wp:attachment":[{"href":"http:\/\/zyg.luchers.cn\/index.php\/wp-json\/wp\/v2\/media?parent=5891"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/zyg.luchers.cn\/index.php\/wp-json\/wp\/v2\/categories?post=5891"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/zyg.luchers.cn\/index.php\/wp-json\/wp\/v2\/tags?post=5891"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}