![]() |
Home
| Calendar
| Mail Lists
| List Archives
| Desktop SIG
| Hardware Hacking SIG
Wiki | Flickr | PicasaWeb | Video | Maps & Directions | Installfests | Keysignings Linux Cafe | Meeting Notes | Linux Links | Bling | About BLU |
I got the following to work. I apologize if this is a repost. Rich. ;;; delete-blank-lines is standard ;;; let me know if it isn't ;;; I couldn't find a built-in that did what you wanted. (defun delete-trailing-blank-lines () (interactive) (goto-char (point-max)) (delete-blank-lines) ) (defun delete-save () (interactive) (delete-trailing-blank-lines) (save-buffer) ) (defun delete-save-some () (interactive) (delete-trailing-blank-lines) (save-some-buffers) ) ;;; the first square is a control as is the second the last is a control-s. (global-set-key "s" 'delete-save-some) (global-set-key "" 'delete-save) Jerry Feldman wrote: > Is there a built-in elisp function that removes extra newlines from the end > of a file being edited. I sometimes leave severay trailing newlines in some > of my files inadvertenly. If there is (either globally in emacs or in c-mode), > what variable does it test when saving the file. > -- > Jerry Feldman > Contractor, eInfrastructure Partner Engineering > 508-467-4315 http://www.testdrive.compaq.com/linux/ > > Compaq Computer Corp. > 200 Forest Street MRO1-3/F1 > Marlboro, Ma. 01752 > - > Subcription/unsubscription/info requests: send e-mail with > "subscribe", "unsubscribe", or "info" on the first line of the > message body to discuss-request at blu.org (Subject line is ignored). - Subcription/unsubscription/info requests: send e-mail with "subscribe", "unsubscribe", or "info" on the first line of the message body to discuss-request at blu.org (Subject line is ignored).
![]() |
|
BLU is a member of BostonUserGroups | |
We also thank MIT for the use of their facilities. |