|
@@ -29,8 +29,8 @@ __die_if() {
|
29
|
29
|
;;
|
30
|
30
|
nobump)
|
31
|
31
|
git diff-tree --no-commit-id --name-only -r HEAD \
|
32
|
|
- | grep -qFx config.mk \
|
33
|
|
- || die "last change must be version bump in config.mk"
|
|
32
|
+ | grep -qFx mkit.ini \
|
|
33
|
+ || die "last change must be version bump in mkit.ini"
|
34
|
34
|
;;
|
35
|
35
|
wip)
|
36
|
36
|
__git_info reldiff \
|
|
@@ -41,7 +41,7 @@ __die_if() {
|
41
|
41
|
x=$(__ver_info nextver_g)
|
42
|
42
|
__ver_info currver_c \
|
43
|
43
|
| grep -qFx "$x" \
|
44
|
|
- || die "new version not in config.mk: $x"
|
|
44
|
+ || die "new version not in mkit.ini: $x"
|
45
|
45
|
;;
|
46
|
46
|
esac
|
47
|
47
|
}
|
|
@@ -66,8 +66,7 @@ __ver_info() {
|
66
|
66
|
case "$info" in
|
67
|
67
|
lastver_g) __git_info lasttag | sed s/^v// ;;
|
68
|
68
|
nextver_g) __make_ver "$level" "$(__ver_info lastver_g)" ;;
|
69
|
|
- currver_c) grep -m 1 -w VERSION config.mk \
|
70
|
|
- | sed 's/ *= */=/' | cut -d = -f 2 | xargs echo ;;
|
|
69
|
+ currver_c) ini 1value project:version ;;
|
71
|
70
|
nextver_c) __make_ver "$level" "$(__ver_info currver_c)" ;;
|
72
|
71
|
esac
|
73
|
72
|
}
|
|
@@ -132,7 +131,7 @@ __git_msg_vbump() {
|
132
|
131
|
|
133
|
132
|
__vbump() {
|
134
|
133
|
local level="$1"
|
135
|
|
- local lastver # current from config.mk
|
|
134
|
+ local lastver # current from mkit.ini
|
136
|
135
|
local nextver # after the bump
|
137
|
136
|
__die_if nogit
|
138
|
137
|
__die_if norelbr
|
|
@@ -141,10 +140,10 @@ __vbump() {
|
141
|
140
|
nextver=$(__ver_info nextver_c)
|
142
|
141
|
debug_var lastver nextver
|
143
|
142
|
$MKIT_DRY && return
|
144
|
|
- sed -i "s/$lastver/$nextver/" config.mk \
|
145
|
|
- || die "failed to update config.mk"
|
146
|
|
- git add config.mk \
|
147
|
|
- || die "failed to add config.mk to the index"
|
|
143
|
+ update_version "$nextver" mkit.ini \
|
|
144
|
+ || die "failed to update version in mkit.ini"
|
|
145
|
+ git add mkit.ini \
|
|
146
|
+ || die "failed to add mkit.ini to the index"
|
148
|
147
|
git commit -e -m "$(__git_msg_vbump)"
|
149
|
148
|
}
|
150
|
149
|
|