zoukankan      html  css  js  c++  java
  • composer version constraint 版本号前缀

    Tilde Version Range (~)
    -- the last second is fixed. except for 0.X
    The ~ operator is best explained by example: ~1.2 is equivalent to >=1.2 <2.0.0, while ~1.2.3 is equivalent to >=1.2.3 <1.3.0. As you can see it is mostly useful for projects respecting semantic versioning. A common usage would be to mark the minimum minor version you depend on, like ~1.2 (which allows anything up to, but not including, 2.0). Since in theory there should be no backwards compatibility breaks until 2.0, that works well. Another way of looking at it is that using ~ specifies a minimum version, but allows the last digit specified to go up.

    Caret Version Range (^)#
    -- the first one is fixed.
    The ^ operator behaves very similarly but it sticks closer to semantic versioning, and will always allow non-breaking updates. For example ^1.2.3 is equivalent to >=1.2.3 <2.0.0 as none of the releases until 2.0 should break backwards compatibility. For pre-1.0 versions it also acts with safety in mind and treats ^0.3 as >=0.3.0 <0.4.0.

    This is the recommended operator for maximum interoperability when writing library code.

    Example: ^1.2.3

    https://getcomposer.org/doc/articles/versions.md#tilde-version-range-

    https://semver.mwl.be

  • 相关阅读:
    梯度下降算法实现
    windows10下Anaconda的安装与tensorflow、opencv的安装与环境配置
    在github创建用户
    看完教材不明白的问题
    自我介绍
    HDU 1098(条件满足 数学)
    HDU 1097(m次幂的个位数 规律)
    HDU 1046(最短路径 **)
    HDU 1045(炮台安置 DFS)
    HDU 1034(传递糖果 模拟)
  • 原文地址:https://www.cnblogs.com/qinqiu/p/8483146.html
Copyright © 2011-2022 走看看