I wrote a long article and at the last paragraph, I decided to edit a sentence, I selected the "region" and pressed C-w to remove it :-( For uninitiated, C-w is "yank text", i.e. cut it, and Firefox it is "close current tab without warning".
C-S-t in Firefox will bring it back. Don't know if the content of the text field remains though.
Ask HN: What's in your .emacs file?
31–40 of 60 posts
Re: Ask HN: What's in your .emacs file?
#32Most important: ;; Don't mix tabs and spaces (setq-default indent-tabs-mode nil) ;; Use "newline-and-indent" when you hit the Enter key so ;; you don't need to keep using TAB to align each line. (global-set-key "\C-m" 'newline-and-indent) ;; Get rid of the with duplicate file names (require 'uniquify) (setq uniquify-buffer-name-style 'post-forward-angle-brackets) And then a whole bunch of autoload statements for diff…
Re: Ask HN: What's in your .emacs file?
#33Most important: ;; Don't mix tabs and spaces (setq-default indent-tabs-mode nil) ;; Use "newline-and-indent" when you hit the Enter key so ;; you don't need to keep using TAB to align each line. (global-set-key "\C-m" 'newline-and-indent) ;; Get rid of the with duplicate file names (require 'uniquify) (setq uniquify-buffer-name-style 'post-forward-angle-brackets) And then a whole bunch of autoload statements for diff…
;; Use "newline-and-indent" when you hit the Enter key so
;; you don't need to keep using TAB to align each line.
(global-set-key "\C-m" 'newline-and-indent)
That's what C-j is for.Re: Ask HN: What's in your .emacs file?
#34Re: Ask HN: What's in your .emacs file?
#35;; Switch buffer
(global-set-key [f5] 'buffer-menu)
;; Save and load
(global-set-key [f2] 'save-buffer)
(global-set-key [f3] 'find-file)
;; Compile file
(global-set-key [f9] 'slime-compile-and-load-file)
;; Goto line
(global-set-key "\M-l" 'goto-line)
;; Go to other window
(global-set-key (kbd "") 'other-window)
;; And probably the most useful one, numpad Enter for eval line:
(global-set-key (kbd "") 'slime-eval-last-expression)
Re: Ask HN: What's in your .emacs file?
#36(require 'activator) (activator-start)
Which then looks at all of the stuff here: http://github.com/apgwoz/emacs-config
Re: Ask HN: What's in your .emacs file?
#37(fset 'yes-or-no-p 'y-or-n-p)
Re: Ask HN: What's in your .emacs file?
#38It's hard to live without: (fset 'yes-or-no-p 'y-or-n-p)
Re: Ask HN: What's in your .emacs file?
#39It's hard to live without: (fset 'yes-or-no-p 'y-or-n-p)