简体   繁体   English

从 Nexus 存储库下载 Pi4j 快照的过程?

[英]Process to download Pi4j snapshot from Nexus repository?

Sorry I am new to this specific scenario.抱歉,我对这种特定情况不熟悉。 I would like to use these newest Pi4j libraries found at this link: https://oss.sonatype.org/content/groups/public/com/pi4j/pi4j-core/2.0-SNAPSHOT/ but its a ton of separate files unlike when I download the 1.2 version of Pi4j from https://pi4j.com/1.2/download.html我想使用在此链接上找到的这些最新的 Pi4j 库: https://oss.sonatype.org/content/groups/public/com/pi4j/pi4j-core/2.0-SNAPSHOT/但它有大量单独的文件,不像当我从https://pi4j.com/1.2/download.html下载 Pi4j 的 1.2 版本时

I've tried to download a few individual files to see if they contained the class definitions I expected but they didn't.我尝试下载一些单独的文件,看看它们是否包含我预期的 class 定义,但它们没有。 Perhaps the naming conventions are throwing me off.也许命名约定让我失望。 Should I download each file individually or is there some process I am completely unfamiliar with?我应该单独下载每个文件还是有一些我完全不熟悉的过程? Sorry if this question seems silly but I'm at a loss.对不起,如果这个问题看起来很愚蠢,但我很茫然。

As V2 of Pi4J is work-in-progress and no "final" versions got released yet, you'll need to add extra repository info to your pom.xml file:由于 Pi4J 的 V2 正在进行中,并且尚未发布“最终”版本,因此您需要在 pom.xml 文件中添加额外的存储库信息:

   <repositories>
        <repository>
            <id>oss-snapshots-repo</id>
            <name>Sonatype OSS Maven Repository</name>
            <url>https://oss.sonatype.org/content/groups/public</url>
            <releases>
                <enabled>false</enabled>
            </releases>
            <snapshots>
                <enabled>true</enabled>
            </snapshots>
        </repository>
    </repositories>

More info is available onhttps://v2.pi4j.com/getting-started/minimal-example-application更多信息可在https://v2.pi4j.com/getting-started/minimal-example-application

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM