diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2006-01-23 10:40:10 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2006-01-23 10:40:10 +0000 |
commit | 4b9a2e7258a0ea307bb631a0fbc5a0b0564a1830 (patch) | |
tree | 0df33f358fdc35c9dcdf4ad125613de9127496b9 /rpm-spec-mode.el | |
parent | 9a3e30fd6624c8c3305954f88904ced72ce7509b (diff) | |
download | rpm-setup-4b9a2e7258a0ea307bb631a0fbc5a0b0564a1830.tar rpm-setup-4b9a2e7258a0ea307bb631a0fbc5a0b0564a1830.tar.gz rpm-setup-4b9a2e7258a0ea307bb631a0fbc5a0b0564a1830.tar.bz2 rpm-setup-4b9a2e7258a0ea307bb631a0fbc5a0b0564a1830.tar.xz rpm-setup-4b9a2e7258a0ea307bb631a0fbc5a0b0564a1830.zip |
handle increasing things like "%mkrel 2"
Diffstat (limited to 'rpm-spec-mode.el')
-rw-r--r-- | rpm-spec-mode.el | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/rpm-spec-mode.el b/rpm-spec-mode.el index f3569af..eea9433 100644 --- a/rpm-spec-mode.el +++ b/rpm-spec-mode.el @@ -1308,7 +1308,10 @@ if one is present in the file." (or (funcall increase-macro macros) (and (search-forward-regexp (concat "%define[ \t]+" macros "[ \t]+%mkrel[ \t]+%{rel}") nil t) - (funcall increase-macro "rel")))))))) + (funcall increase-macro "rel")) + (and (search-forward-regexp "\\(%mkrel[ \t]+\\)\\([0-9]+\\)$" nil t) + (replace-match (concat (match-string 1) (int-to-string (1+ (string-to-int (match-string 2))))))) + )))))) ;;------------------------------------------------------------ |