Browse Source

increase-version-number: support "+" inside version string.

tags/sipwise-2.4
Michael Prokop Michael Prokop 10 years ago
parent
commit
c0b1838742
2 changed files with 3 additions and 2 deletions
  1. +2
    -2
      increase-version-number
  2. +1
    -0
      tests/increase-version-number

+ 2
- 2
increase-version-number View File

@@ -9,8 +9,8 @@ fi

PREVIOUS_VERSION="$1"

# remove Debian parts of version number (-1*, ~1*)
BASE_VERSION=$(echo ${PREVIOUS_VERSION} | sed 's/\(-.*\)\|\(~.*\)$//')
# remove Debian parts of version number (-1*, ~1*, +1*)
BASE_VERSION=$(echo ${PREVIOUS_VERSION} | sed 's/\(-.*\)\|\(~.*\)\|\(+.*\)$//')

# if a Debian version is present, then use '-1' inside snapshot version
DEBIAN_VERSION=''


+ 1
- 0
tests/increase-version-number View File

@@ -16,6 +16,7 @@ testEquality()
assertEquals "$($SCRIPT 0.9.00)" 0.9.01
assertEquals "$($SCRIPT 0.8)" 0.9
assertEquals "$($SCRIPT 0.9)" 0.10
assertEquals "$($SCRIPT 3.1.4+1)" 3.1.5
}

. /usr/share/shunit2/shunit2

Loading…
Cancel
Save