Commit 21ae820e authored by Per Cederqvist's avatar Per Cederqvist
Browse files

(renumber-lyskom-send-simple-expect-indented): New function.

parent 3acae75d
......@@ -39,3 +39,21 @@
"^\\(simple\\|extracting\\|good_bad\\)_expect \"[%=]\\([0-9]+\\)"
limit t)
(replace-match (format "%d" ref-nr) t t nil 2))))))
;;;###autoload
(defun renumber-lyskom-send-simple-expect-indented ()
(interactive)
(goto-char (point-min))
(let ((ref-nr 1999)
(case-fold-search nil))
(while (re-search-forward "^ send \"\\([0-9]+\\) " nil t)
(setq ref-nr (+ 1 ref-nr))
(replace-match (format "%d" ref-nr) t t nil 1)
(let ((pos (point))
(limit (re-search-forward "^ \\(send\\)\\|\\(talk_to\\)" nil t)))
(goto-char pos)
(while
(re-search-forward
"^ \\(simple\\|extracting\\|good_bad\\)_expect \"[%=]\\([0-9]+\\)"
limit t)
(replace-match (format "%d" ref-nr) t t nil 2))))))
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment