皆んさんの .emacs はどんな感じですか? まずは自分から
custom-set-variablesの引数に
'(file-coding-system-alist (cons (quote ("gauche-refj\\.info.*\\'" utf-8 . utf-8)) file-coding-system-alist))
こんなのを貼っておくといいみたいです(び 2006/03/03 20:29:16 PST)。
;(setq gauche-man-base "http://practical-scheme.net/wiliki/schemexref.cgi?") (setq gauche-man-base "http://practical-scheme.net/gauche/man/?l=en&p=") (defun gauche-man () (interactive) (let ((key (if (use-region-p) (buffer-substring-no-properties (region-beginning) (region-end)) (thing-at-point 'symbol)))) (browse-url (concat gauche-man-base key)))) (add-hook 'scheme-mode-hook (function (lambda () (define-key scheme-mode-map "\C-c\C-f" 'gauche-man))))
(setq scheme-program-name "gosh") ; "gosh -i" にするとプロンプトが出る。 (put 'and-let* 'scheme-indent-function 1) (put 'begin0 'scheme-indent-function 0) (put 'call-with-client-socket 'scheme-indent-function 1) (put 'call-with-input-conversion 'scheme-indent-function 1) (put 'call-with-input-file 'scheme-indent-function 1) (put 'call-with-input-process 'scheme-indent-function 1) (put 'call-with-input-string 'scheme-indent-function 1) (put 'call-with-iterator 'scheme-indent-function 1) (put 'call-with-output-conversion 'scheme-indent-function 1) (put 'call-with-output-file 'scheme-indent-function 1) (put 'call-with-output-string 'scheme-indent-function 0) (put 'call-with-temporary-file 'scheme-indent-function 1) (put 'call-with-values 'scheme-indent-function 1) (put 'dolist 'scheme-indent-function 1) (put 'dotimes 'scheme-indent-function 1) (put 'if-match 'scheme-indent-function 2) (put 'let*-values 'scheme-indent-function 1) (put 'let-args 'scheme-indent-function 2) (put 'let-keywords* 'scheme-indent-function 2) (put 'let-match 'scheme-indent-function 2) (put 'let-optionals* 'scheme-indent-function 2) (put 'let-syntax 'scheme-indent-function 1) (put 'let-values 'scheme-indent-function 1) (put 'let/cc 'scheme-indent-function 1) (put 'let1 'scheme-indent-function 2) (put 'letrec-syntax 'scheme-indent-function 1) (put 'make 'scheme-indent-function 1) (put 'multiple-value-bind 'scheme-indent-function 2) (put 'parameterize 'scheme-indent-function 1) (put 'parse-options 'scheme-indent-function 1) (put 'receive 'scheme-indent-function 2) (put 'rxmatch-case 'scheme-indent-function 1) (put 'rxmatch-cond 'scheme-indent-function 0) (put 'rxmatch-if 'scheme-indent-function 2) (put 'rxmatch-let 'scheme-indent-function 2) (put 'syntax-rules 'scheme-indent-function 1) (put 'unless 'scheme-indent-function 1) (put 'until 'scheme-indent-function 1) (put 'when 'scheme-indent-function 1) (put 'while 'scheme-indent-function 1) (put 'with-builder 'scheme-indent-function 1) (put 'with-error-handler 'scheme-indent-function 0) (put 'with-error-to-port 'scheme-indent-function 1) (put 'with-input-conversion 'scheme-indent-function 1) (put 'with-input-from-port 'scheme-indent-function 1) (put 'with-input-from-process 'scheme-indent-function 1) (put 'with-input-from-string 'scheme-indent-function 1) (put 'with-iterator 'scheme-indent-function 1) (put 'with-module 'scheme-indent-function 1) (put 'with-output-conversion 'scheme-indent-function 1) (put 'with-output-to-port 'scheme-indent-function 1) (put 'with-output-to-process 'scheme-indent-function 1) (put 'with-output-to-string 'scheme-indent-function 1) (put 'with-port-locking 'scheme-indent-function 1) (put 'with-string-io 'scheme-indent-function 1) (put 'with-time-counter 'scheme-indent-function 1) (put 'with-signal-handlers 'scheme-indent-function 1)
mic-paren.elをロードパスに。 .emacsに以下を追加。
(require 'mic-paren) (paren-activate) (setq paren-match-face 'bold) (setq paren-sexp-mode t)
以下を .emacs に入れて、(use PKG) や (require PKG) の PKG のところで、C-x C-f すると、そのライブラリのファイルが開けます。(同様に C-x C-r などでも)
(ffap-bindings) (defun ffap-gauche (pkg) (let ((tl (concat (subst-char-in-string ?. ?/ pkg) ".scm")) path) (dolist (hd (car (read-from-string (shell-command-to-string "echo | gosh -E 'write *load-path*'")))) (setq path (concat hd "/" tl)) (when (file-regular-p path) (return path))))) (eval-after-load "ffap" '(add-to-list 'ffap-alist '(scheme-mode . ffap-gauche)))
人によってカスタマイズした方がいいかもしれない部分は以下です