Merge commit 'jao/emacs'
commit
9f0643a96d
|
@ -75,6 +75,7 @@ beast.
|
|||
- C-cz : switch to listener
|
||||
- C-co : cycle between code, tests and docs factor files
|
||||
- C-cs : switch to other factor buffer (M-x fuel-switch-to-buffer)
|
||||
- C-cr : switch to listener and refresh all loaded vocabs
|
||||
- C-x4s : switch to other factor buffer in other window
|
||||
- C-x5s : switch to other factor buffer in other frame
|
||||
|
||||
|
@ -86,7 +87,7 @@ beast.
|
|||
- C-cC-ew : edit word (M-x fuel-edit-word-at-point)
|
||||
- C-cC-ed : edit word's doc (M-x fuel-edit-word-at-point)
|
||||
|
||||
- C-cr, C-cC-er : eval region
|
||||
- C-cC-er : eval region
|
||||
- C-M-r, C-cC-ee : eval region, extending it to definition boundaries
|
||||
- C-M-x, C-cC-ex : eval definition around point
|
||||
- C-ck, C-cC-ek : run file
|
||||
|
@ -110,6 +111,7 @@ beast.
|
|||
|
||||
- TAB : complete word at point
|
||||
- M-. : edit word at point in Emacs
|
||||
- C-cr : refresh all loaded vocabs
|
||||
- C-ca : toggle autodoc mode
|
||||
- C-cp : find words containing given substring (M-x fuel-apropos)
|
||||
- C-cs : toggle stack mode
|
||||
|
|
|
@ -107,15 +107,9 @@ buffer."
|
|||
(goto-char (point-max))
|
||||
(unless seen (error "No prompt found!"))))
|
||||
|
||||
(defun fuel-listener-nuke ()
|
||||
(interactive)
|
||||
(goto-char (point-max))
|
||||
(comint-kill-region comint-last-input-start (point))
|
||||
(comint-redirect-cleanup)
|
||||
(fuel-con--setup-connection fuel-listener--buffer))
|
||||
|
||||
|
||||
;;; Interface: starting fuel listener
|
||||
;;; Interface: starting and interacting with fuel listener:
|
||||
|
||||
(defalias 'switch-to-factor 'run-factor)
|
||||
(defalias 'switch-to-fuel-listener 'run-factor)
|
||||
|
@ -129,6 +123,23 @@ buffer."
|
|||
(pop-to-buffer buf)
|
||||
(switch-to-buffer buf))))
|
||||
|
||||
(defun fuel-listener-nuke ()
|
||||
"Try this command if the listener becomes unresponsive."
|
||||
(interactive)
|
||||
(goto-char (point-max))
|
||||
(comint-kill-region comint-last-input-start (point))
|
||||
(comint-redirect-cleanup)
|
||||
(fuel-con--setup-connection fuel-listener--buffer))
|
||||
|
||||
(defun fuel-refresh-all ()
|
||||
"Switch to the listener buffer and invokes Factor's refresh-all.
|
||||
With prefix, you're teletransported to the listener's buffer."
|
||||
(interactive)
|
||||
(let ((buf (process-buffer (fuel-listener--process))))
|
||||
(pop-to-buffer buf)
|
||||
(comint-send-string nil "\"Refreshing loaded vocabs...\" write nl flush")
|
||||
(comint-send-string nil " refresh-all \"Done!\" write nl flush\n")))
|
||||
|
||||
|
||||
;;; Completion support
|
||||
|
||||
|
@ -172,6 +183,7 @@ buffer."
|
|||
(define-key fuel-listener-mode-map "\C-a" 'fuel-listener--bol)
|
||||
(define-key fuel-listener-mode-map "\C-ca" 'fuel-autodoc-mode)
|
||||
(define-key fuel-listener-mode-map "\C-ch" 'fuel-help)
|
||||
(define-key fuel-listener-mode-map "\C-cr" 'fuel-refresh-all)
|
||||
(define-key fuel-listener-mode-map "\C-cs" 'fuel-stack-mode)
|
||||
(define-key fuel-listener-mode-map "\C-cp" 'fuel-apropos)
|
||||
(define-key fuel-listener-mode-map "\M-." 'fuel-edit-word-at-point)
|
||||
|
|
|
@ -175,7 +175,7 @@ interacting with a factor listener is at your disposal.
|
|||
|
||||
(fuel-mode--key-1 ?k 'fuel-run-file)
|
||||
(fuel-mode--key-1 ?l 'fuel-run-file)
|
||||
(fuel-mode--key-1 ?r 'fuel-eval-region)
|
||||
(fuel-mode--key-1 ?r 'fuel-refresh-all)
|
||||
(fuel-mode--key-1 ?z 'run-factor)
|
||||
(fuel-mode--key-1 ?s 'fuel-switch-to-buffer)
|
||||
(define-key fuel-mode-map "\C-x4s" 'fuel-switch-to-buffer-other-window)
|
||||
|
|
Loading…
Reference in New Issue