When automatically building unstable packages, buildbot increases
the version and appends the UNIX time as release. However, the
version should not be increased.
This commit modifies buildbot so that it only appends the UNIX time
as release number, when building from unstable branches.
local verrel="$1"
local version
- local version_prefix
- local version_suffix
local unixtime
version="${verrel%-*}"
- version_prefix="${version%.*}"
- version_suffix="${version##*.}"
-
- if ! is_digits "$version_suffix"; then
- return 1
- fi
-
- (( version_suffix++ ))
-
if ! unixtime=$(date +"%s"); then
return 1
fi
- echo "$version_prefix.$version_suffix-$unixtime"
+ echo "$version-$unixtime"
return 0
}