(setq-default grep-string "")
(setq-default grep-files "")
(defun
    (grep string files bname
	(setq string (arg 1 ": string: "))
	(if (= string "")
	    (if (= grep-string "")
		(error-message "no previous string")
		(setq string grep-string))
	    (setq grep-string string))
	(setq files (arg 2 ": file(s): "))
	(if (= files "")
	    (if (= grep-files "")
		(error-message "no previous files")
		(setq files grep-files))
	    (setq grep-files files))
	(setq bname (current-buffer-name))
	(pop-to-buffer "Error log")	; to make it pop up
	(pop-to-buffer bname)
	(provide-prefix-argument 1 (compile-it
	    (concat "emacs:grep -n """ string """ " files)))
	(novalue)
    )
)
(novalue)
