X-Git-Url: https://git.distorted.org.uk/~mdw/skel/blobdiff_plain/89b7a3ae81e08415c68518d54c5d3c6ac25b9b66..3a2c646eb9a1dcac26941daa82fb024b6fd77cfe:/skel.el.in diff --git a/skel.el.in b/skel.el.in index 86ce7eb..154eb1f 100644 --- a/skel.el.in +++ b/skel.el.in @@ -13,12 +13,12 @@ ;;; it under the terms of the GNU General Public License as published by ;;; the Free Software Foundation; either version 2 of the License, or ;;; (at your option) any later version. -;;; +;;; ;;; This program is distributed in the hope that it will be useful, ;;; but WITHOUT ANY WARRANTY; without even the implied warranty of ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;;; GNU General Public License for more details. -;;; +;;; ;;; You should have received a copy of the GNU General Public License ;;; along with this program; if not, write to the Free Software Foundation, ;;; Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. @@ -138,7 +138,7 @@ (let ((pair (assq name skel-alist)) value) (if pair - (save-match-data (setq value (eval (cdr pair)))) + (setq value (eval (cdr pair))) (setq value (read-string (format "Value for %s: " name))) (setq skel-alist (cons (cons name value) skel-alist))) value)) @@ -151,7 +151,9 @@ buffer at this point." (if (re-search-forward "\\[\\[\\([^]]*\\)\\]\\]" nil t) (progn - (replace-match (skel-lookup (match-string 1)) t t nil) + (replace-match (save-match-data + (skel-lookup (match-string 1))) + t t nil) (goto-char (match-beginning 0)) (skel-do-fill-in)))) @@ -236,7 +238,7 @@ "Like skel-create-file, but in another window." (interactive "FSkeleton create file in other window: \nP") (skel-do-create-file name 'switch-to-buffer-other-window skel)) - + (defun skel-create-file-other-frame (name &optional skel) "Like skel-create-file, but in another frame." (interactive "FSkeleton create file in other frame: \nP")