मुझे कुछ सीमाओं के कारण पूरी तरह ऑफ़लाइन मैवेन रिपोजिटरी की आवश्यकता है। http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException के अनुसार, केवल <pluginRepositories>
प्लगइन के लिए खोजे गए हैं। तो मैं सोच रहा हूं कि एक स्थानीय फाइल सिस्टम में प्लगइन देखने के लिए मेवेन को कैसे कॉन्फ़िगर करना है। मैंने <url>
सेट करते समय "फ़ाइल: //" उपसर्ग का उपयोग करने का प्रयास किया लेकिन यह काम नहीं करता है।मैवेन 3 स्थानीय प्लगइन रिपोजिटरी कैसे सेट करें
DEBUG] Verifying availability of /home/dsun/.m2/repository/org/apache/karaf/tooling/features-maven-plugin/2.3.0/features-maven-plugin-2.3.0.jar from [central (http://repo1.maven.org/maven2, releases=true, snapshots=false, managed=false)]
[ERROR] Plugin org.apache.karaf.tooling:features-maven-plugin:2.3.0 or one of its dependencies could not be resolved: The repository system is offline but the artifact org.apache.karaf.tooling:features-maven-plugin:jar:2.3.0 is not available in the local repository. -> [Help 1]
org.apache.maven.plugin.PluginResolutionException: Plugin org.apache.karaf.tooling:features-maven-plugin:2.3.0 or one of its dependencies could not be resolved: The repository system is offline but the artifact org.apache.karaf.tooling:features-maven-plugin:jar:2.3.0 is not available in the local repository.
[email protected]:> ls /home/dsun/.m2/repository/org/apache/karaf/tooling/features-maven-plugin/2.3.0/features-maven-plugin-2.3.0.jar
/home/dsun/.m2/repository/org/apache/karaf/tooling/features-maven-plugin/2.3.0/features-maven-plugin-2.3.0.jar
settings.xml
<settings>
<offline>true</offline>
<profiles>
<profile>
<id>local</id>
<pluginRepositories>
<pluginRepository>
<id>central</id>
<url>file://${env.HOME}/.m2/repository</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
</profiles>
<activeProfiles>
<activeProfile>local</activeProfile>
</activeProfiles>
<localRepository>${env.HOME}/.m2/repository</localRepository>
मुझे यकीन नहीं है, लेकिन शायद यह पोस्ट आपके लिए सहायक होगा: http://stackoverflow.com/questions/5141211/maven-without-remote-repository –
आपकी कॉन्फ़िगरेशन काम नहीं कर सकती क्योंकि आप परिभाषित कर रहे हैं स्रोत भंडार लक्ष्य भंडार (.m2/भंडार) के समान ही है। आपको प्रारंभिक बूट पट्टा होना चाहिए जहां से आपके सभी बिल्ड काम शुरू हो रहे हैं और बाद में आप सेटअप कर सकते हैं। – khmarbaise
हाय खम्बाबाइज, क्या आप इसे विवरण में समझा सकते हैं? आपका मतलब क्या है "स्रोत भंडार"? आवश्यक प्लगइन पहले से ही मेरे स्थानीय भंडार में है। और मैंने को छोड़कर settings.xml में सभी पंक्तियों को निकालने का प्रयास किया, यह भी काम नहीं करता है। –
SunLiWei