[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Removing the last entry from the kill-ring
From: |
Cecil Westerhof |
Subject: |
Removing the last entry from the kill-ring |
Date: |
Sun, 12 Jan 2014 18:30:36 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux) |
I wrote the following function, to copy the current buffer to a
temporary buffer:
(defun dcbl-buffer-to-temp ()
(interactive)
(let ((buffer-name (generate-new-buffer-name "tempory-edit")))
(copy-region-as-kill (point-min) (point-max))
(switch-to-buffer buffer-name)
(yank)))
This works OK (I think) except for one problem: there is an entry
added to the kill-ring. Is there a way to remove this?
--
Cecil Westerhof
Senior Software Engineer
LinkedIn: http://www.linkedin.com/in/cecilwesterhof
- Removing the last entry from the kill-ring,
Cecil Westerhof <=