版本-maven-plugin中的奇怪maven版本范围

时间:2017-07-03 06:53:47

标签: maven plugins version versions-maven-plugin

我看到[1.1,2.0]或[1.1,)的范围 但这意味着什么:

  <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>versions-maven-plugin</artifactId>
                    <configuration>
                        <properties>
                            <property>
                                <name>security-api</name>
                                <version>[1.4,1.4.1-!)</version>
                            </property>

-! [1.4,1.4.1-!)是否特定于版本maven-plugin,其目的是什么?

1 个答案:

答案 0 :(得分:1)

@Directive({ selector: '[test-directive]' }) export class TestDirective implements OnInit { @Input("test-directive") testDirective: string; constructor(private el: ElementRef, private renderer: Renderer) { } ngOnInit() { console.log("color is = " + this.testDirective); this.renderer.setElementStyle(this.el.nativeElement, 'background-color', this.testDirective); } } 中的感叹号用于阻止使用[1.4,1.4.1-!)版本(以及其他类似版本,例如1.4.1-SNAPSHOT),因为-alpha允许[1.4,1.4.1)使用。

,至少使用Maven 3.5.0,1.4.1-SNAPSHOT范围也允许使用[1.4,1.4.1-!)

这样做是因为,在ASCII中,1.4.1无论如何都低于!

相关问题