Class: TroubleShooting

Inherits:
Object show all
Defined in:
lib/xiki/trouble_shooting.rb

Class Method Summary collapse

Class Method Details

.keysObject



2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# File 'lib/xiki/trouble_shooting.rb', line 2

def self.keys
  return if ! $el

  $el.el4r_lisp_eval %`
    (progn
      (global-set-key (kbd "M-l") (lambda () (interactive)
        "Load .emacs (reloading EmacsRuby)"
        (switch-to-buffer "*el4r:process*")
        (kill-buffer "*el4r:process*")
        (load-file "~/.emacs")
      ))
      (global-set-key (kbd "M-e")  (lambda () (interactive)
      "Go to EmacsRuby error"
        (find-file el4r-log-path)
        (revert-buffer t t t)
        (setq truncate-lines nil)
        (end-of-buffer)
        (re-search-backward "^  from ")
        (re-search-backward "^\\\\S-")
        (recenter 0)
      ))
    )
    `
end