;;; Common setting for FSF Emacs and XEmacs ;; Copyright (C) 2000 Yuji 'bmonkey' Minejima ;; Author: Yuji Minejima ;; $Revision: 1.236 $ ;; This file is NOT part of GNU Emacs. ;; This program is free software; you can redistribute it and/or modify ;; it under the terms of the GNU General Public License as published by ;; the Free Software Foundation; either version 2, or (at your option) ;; any later version. ;; This program is distributed in the hope that it will be useful, but ;; WITHOUT ANY WARRANTY; without even the implied warranty of ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ;; General Public License for more details. ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, ;; Boston, MA 02111-1307, USA. ;;; Define initialization utilities (defconst bm-init-log-buffer "*Init-Log*" "Buffer name for `bm-init'.") (defun bm-init-log (message forms) "Logging function for `bm-init'." (with-current-buffer (get-buffer-create bm-init-log-buffer) (require 'pp) (insert " \n" message " >>>\n") (mapcar (lambda (form) (pp form (current-buffer))) forms) (insert "\n" " <<<\n\n")) (switch-to-buffer-other-window (get-buffer bm-init-log-buffer)) (goto-char (point-min))) (defmacro bm-init (section &rest forms) "Eval SECTION comprising FORMS in a protected environment." (if (stringp section) (list 'condition-case 'err (cons 'progn forms) (list 'error (list 'bm-init-log (list 'concat (format "While evaluating \"%s\" section:\n" section) " !! " '(error-message-string err) "\n") (list 'quote forms)))) (setq forms (list (cons 'bm-init (cons section forms)))) (bm-init-log (concat "While expanding `bm-init' macro call:\n" " !! First argument to bm-init must be a title string\n") forms))) (bm-init "bm-init goodies" (put 'bm-init 'lisp-indent-function 'defun) ; indentation info (def-edebug-spec bm-init (stringp body)) ; debugging info (when (fboundp 'font-lock-add-keywords) ; fontlock (font-lock-add-keywords 'emacs-lisp-mode '(("^(bm-init \\(.+\\)" 1 font-lock-warning-face t))))) (setq emacs21 (and (not (featurep 'xemacs)) (= emacs-major-version 21))) ;;; Initialization begins (bm-init "local libraries and maintenance tools" (let* ((site-lisp (format "/usr/local/share/%semacs/site-lisp" (if (featurep 'xemacs) "x" ""))) (ver-site-lisp (format "/usr/local/share/%semacs/%s.%s/site-lisp" (if (featurep 'xemacs) "x" "") emacs-major-version emacs-minor-version))) (setq bm-lib-mnt-autoload-alist ;; ( (loaddefs.el . (dir1 dir2 ...))... ) (list (cons (expand-file-name "site-loaddefs.el" site-lisp) (delq 'nil (mapcar (lambda (dir) (setq dir (file-name-directory dir)) ; "/foo" => "/foo/" (if (string-match (concat "\\`" site-lisp "/elisp/") dir) dir nil)) load-path))))) (setq bm-lib-mnt-src-bin-dir-tree-map ;; ((src-dir . bin-dir) ...) (list (cons (expand-file-name "elisp" site-lisp) (expand-file-name "elisp" ver-site-lisp)))) (require 'bm-lib-mnt) (unless emacs21 (bm-lib-mnt)))) (bm-init "Language & coding system" (set-language-environment "Japanese") (set-default-coding-systems 'euc-jp)) (bm-init "Japanese input method" (cond ((load "canna" "MISSING-OK") ;;these must be set before calling (canna) ;;;(setq canna-use-color '("black/#99bb99" "white/blue" "red/white")) ;;;(setq canna-underline t) ;;;(setq canna-with-fences t) (canna) (setq canna-initialize-minibuffer-state-when-exit t) ;;;(setq canna-save-undo-text-predicate ; condition to push into undo buffer ;;; '(lambda (s) (> (length (car s)) 2)) ) ;;;(setq canna-undo-hook ; undo + something ;;; '(lambda () (message "re-translating....") ;;; (canna-do-function canna-func-henkan)) ) (defun bm-canna-delete-backward-char () "Delete a backward character in Canna fence mode." (interactive) (canna:functional-insert-command2 8 "dummy")) (defun bm-canna-delete-char () "Delete a character in Canna fence mode." (interactive) (canna:functional-insert-command2 4 "dummy")) (defun bm-make-one-entry-keymap (key binding) "Return a keymap which has KEY bound to BINDING." (let ((keymap (make-sparse-keymap))) (define-key keymap key binding) keymap)) ;; **** Canna fence mode key binding *** ;; Linux console's key to character/string mapping. ;; -------------------------------------------------------------- ;; key character/string ;; -------------------------------------------------------------- ;; backspace DEL (decimal code 127) ;; delete ESC [ 3 ~ (private control sequence) ;; control + h BS (decimal code 8) ;; -------------------------------------------------------------- ;; Physical backspace key binding (define-key canna-mode-map [(backspace)] 'bm-canna-delete-backward-char) (define-key canna-mode-map [(127)] 'bm-canna-delete-backward-char) ;; Physical delete key binding (define-key canna-mode-map [(delete)] 'bm-canna-delete-char) (define-key canna-mode-map;; bind "\e[3~" "\e" (bm-make-one-entry-keymap "[" (bm-make-one-entry-keymap "3" (bm-make-one-entry-keymap "~" 'bm-canna-delete-char)))) ;; Control + h (define-key canna-mode-map [(control ?h)] help-map) (global-set-key "\C-cor" 'canna-touroku) (global-set-key "\C-co\C-r" 'canna-touroku-region) (global-set-key "\C-o" 'canna-toggle-japanese-mode) (set-terminal-coding-system 'euc-jp) ) ((load "yc" "MISSING-OK") ) (t (message "No Japanese input method available.")))) (bm-init "Autoloads" (autoload 'find-el "find-el" "" t) (autoload 'color-theme-select "color-theme" "" t) (autoload 'lookup "lookup" "" t) (autoload 'lookup-region "lookup" "" t) (autoload 'lookup-pattern "lookup" "" t) (autoload 'find-function "find-func" "" t) (autoload 'find-function-other-window "find-func" "" t) (autoload 'find-function-other-frame "find-func" "" t) (autoload 'find-function-on-key "find-func" "" t) (autoload 'find-variable "find-func" "" t) (autoload 'find-variable-other-window "find-func" "" t) (autoload 'find-variable-other-frame "find-func" "" t) (autoload 'window-line-mode "window-lines" "Toggle window line mode. With positive ARGument, turn on, else off. At the end, window-line-mode-hook is called. See run-hooks for hook variable." t) (autoload 'gtags-mode "gtags" "Minor mode for browsing C source using GLOBAL." t) ) (bm-init "Options" (unless line-number-mode (line-number-mode 1)) (setq next-line-add-newlines nil) ; prevent C-n from adding new line (setq transient-mark-mode t) ; region gets hilighted (setq scroll-step 1) ; scroll one line at a time (setq scroll-conservatively 1) (setq scroll-margin 0) (setq search-highlight t) ; highlight search hits (auto-compression-mode t) ; auto expand compressed files (setq garbage-collection-messages t) ; garbage collection message on ;(setq gc-cons-threshold 500000) ; garbage collection threshold ;(setq completion-ignore-case t) (setq apropos-do-all t)) (bm-init "Custom edit commands" (require 'bm-util) (global-set-key [f8] 'bm-switch-to-scratch-buffer) (global-set-key [(control tab)] 'bm-switch-to-other-buffer) (global-set-key "\M-d" 'bm-delete-token) (global-set-key "\M-D" 'kill-word) ;;;(global-set-key "\M-f" 'bm-forward-token) ;;;(global-set-key "\M-F" 'forward-word) ;;;(global-set-key "\M-b" 'bm-backward-one-token) ;;;(global-set-key "\M-B" 'backward-word) ;;;(global-set-key "\M-p" 'other-window) ) (bm-init "global key binding" ;(global-set-key [(meta /)] 'hippie-expand) ;;;(global-set-key [(backspace)] 'delete-backward-char) (global-set-key [(delete)] 'delete-char) ;;;(global-set-key [f1] 'delete-other-windows) ;;;(global-set-key [f2] 'bm-switch-to-buffer-other-window-other-buffer) ;;;(global-set-key [f9] 'bm-mew-other-frame) ;;;(global-set-key [f12] 'gnus-other-frame) (global-set-key [(control ?\;)] 'lookup-pattern) (global-set-key [(control return)] 'bm-follow-link) (global-set-key [(control ?\8)] 'insert-parentheses) (global-set-key "\C-xl" 'lookup) (global-set-key "\C-x\C-q" 'toggle-read-only) (global-set-key [?\C-x ?\C-2] 'split-window-vertically) (global-set-key "\C-xk" 'bm-kill-current-buffer) ;;;(global-set-key "\C-xrt" 'bm-insert-string-rectangle) ;;;(global-set-key "\C-x2" 'bm-switch-to-buffer-other-window-other-buffer) (global-set-key "\C-xE" 'bm-exec-script-buffer) (global-set-key "\C-x\M-e" 'eval-buffer) (global-set-key "\M-]" 'delete-other-windows) (define-key ctl-x-map "F" 'find-function) (define-key ctl-x-4-map "F" 'find-function-other-window) (define-key ctl-x-5-map "F" 'find-function-other-frame) (define-key ctl-x-map "K" 'find-function-on-key) (define-key ctl-x-map "V" 'find-variable) (define-key ctl-x-4-map "V" 'find-variable-other-window) (define-key ctl-x-5-map "V" 'find-variable-other-frame) (unless (lookup-key global-map "\C-xrd") (global-set-key "\C-xrd" 'delete-rectangle)) ;;;(global-set-key "\C-c\C-o" 'oo-browser) ) (bm-init "Keymap for custom commands" (let ((map (make-sparse-keymap))) (global-set-key (if window-system [(control ?,)] [(control ?c)]) map) (define-key map "=" 'bm-show-code-mode) (define-key map "e" 'bm-find-elisp-symbol) (define-key map "\C-e" 'find-el) (define-key map "p" 'bm-perl-find) (define-key map "P" 'bm-perl-grep-perldoc) (define-key map "c" 'iman) (define-key map "r" 'bm-rfc-find) (define-key map "y" 'bm-syntax-show-descriptor) (define-key map "b" 'bookmark-jump) (define-key map "v" 'quick-calc) (define-key map "j" 'goto-line) (define-key map "l" '(lambda () (interactive) (recenter 0))) (define-key map "\C-l" '(lambda () (interactive) (recenter -1))) (define-key map "a" 'bm-insert-info-link) (define-key map "n" 'bm-goto-link) (define-key map "s" 'bm-shell) (define-key map "8" 'bm-tab8) (define-key map "4" 'bm-tab4) (define-key map "0" 'bm-kill-buffer-and-window) (define-key map "i" 'bm-right-justify-from-here) )) ;;; Minor modes, buffer local options ; (bm-init "Auto fill mode" ; (mapcar #'(lambda (mode) (add-hook mode 'turn-on-auto-fill)) ; '(text-mode-hook))) (bm-init "jrsearch: search Japanese text by katakana keyseq" (unless emacs21 (load-library "jrsearch") (setq jrsearch-perl "/usr/bin/perl-5.005") (setq jrsearch-isearch-enable-p canna:*japanese-mode*) (defadvice canna-toggle-japanese-mode (after jrsearch-mode activate) (setq jrsearch-isearch-enable-p canna:*japanese-mode*)))) (bm-init "tmenu: Text based interface for menus" (autoload 'tmenu-menubar "tmenu" "text based interface for menu bar" t) (global-set-key [(f10)] 'tmenu-menubar) (global-set-key "\M-`" 'tmenu-menubar)) (bm-init "Screen Lines minor mode" ;;(add-hook 'screen-lines-load-hook ;; #'(lambda () ;; (ad-disable-advice 'kill-line 'around 'screen-lines) ;; (ad-activate 'kill-line))) (require 'screen-lines) (unless emacs21 (setq-default screen-lines-mode t))) (bm-init "Completion ignore case" (mapcar #'(lambda (function) (ad-add-advice function (ad-make-advice 'completion-ignore-case ; name symbol of this advice nil ; protect? t ; enable? '(advice lambda () "Set `completion-ignore-case' to t." (let ((completion-ignore-case t)) ad-do-it))) 'around ; class 'first) ; position (ad-activate function)) '(switch-to-buffer))) (bm-init "color theme" (load "bm-color-theme") (add-hook 'after-make-frame-hook #'(lambda () (my-color-theme)))) (bm-init "iswitch buffer" (iswitchb-default-keybindings)) ;(bm-init "icomplete" ; (icomplete-mode)) ; (bm-init "sw-complete" ; (setq sw-complete-prefix-match-exhibit-unique-match-face ; 'gnus-summary-high-ticked-face ; sw-complete-substring-match-exhibit-unique-match-face ; 'gnus-summary-high-ticked-face ; sw-complete-prefix-match-exhibit-multiple-match-face ; 'gnus-summary-normal-ticked-face ; sw-complete-substring-match-exhibit-multiple-match-face ; 'gnus-summary-normal-ticked-face) ; (sw-complete-mode)) (bm-init "mcomplete" (require 'mcomplete) (turn-on-mcomplete-mode) (put 'bookmark-jump 'mcomplete-mode '(:exhibit-start-chars 0)) (put 'sgml-insert-element 'mcomplete-mode '(:exhibit-start-chars 0)) (global-set-key [f9] 'imenu) ;; This is how you customize mcomplete.el for a command. ;; Unfortunately it doesn't work for imenu.el. ;; (put 'imenu ;; 'mcomplete-mode ;; '(:method-set (mcomplete-substr-method mcomplete-prefix-method) ;; :exhibit-start-chars 0 ;; :ignore-case on)) (defadvice imenu--completion-buffer (around mcomplete activate preactivate) "Support for mcomplete-mode." (require 'mcomplete) (let ((imenu-always-use-completion-buffer-p 'never) (mode mcomplete-mode) ;; the order of completion methods (mcomplete-default-method-set '(mcomplete-substr-method mcomplete-prefix-method)) ;; when to display completion candidates in the minibuffer (mcomplete-default-exhibit-start-chars 0) (completion-ignore-case t)) ;; display *Completions* buffer on entering the minibuffer (setq unread-command-events (cons (funcall (if (fboundp 'character-to-event) 'character-to-event 'identity) ?\?) unread-command-events)) (turn-on-mcomplete-mode) (unwind-protect ad-do-it (unless mode (turn-off-mcomplete-mode)))))) (bm-init "completing-help" (unless emacs21 (require 'evi)) ;; evi is an Emacsen compatibility library used in `lookup'. ;; We need to load evi first then completing-help, since evi redefines ;; completing-read and completing-help advises completing-read, otherwise ;; advise gets corrupted and infinit function call occurs (require 'completing-help) (turn-on-completing-help-mode)) (bm-init "bm-do-smthg" (add-hook 'find-file-hooks (lambda () (when (equal (file-name-nondirectory (buffer-file-name)) "cref.txt") (require 'bm-thing) (setq bm-thing-checklist (append bm-thing-checklist (list 'bm-thing-section))))))) (bm-init "semi" (setq mailcap-file "/etc/mailcap")) ; (bm-init "Remembrance agent" ; (load "remem") ; (setq remem-database-dir "~/.ra-index") ; (setq remem-scopes-list '(("perl" 2 5 500)))) (bm-init "Mew (mail user agent)" (load "~/.mew")) (bm-init "NetNews" (setq message-post-method '(nntp "127.0.0.1"))) (bm-init "lookup (dictionary search)" (setq lookup-enable-splash t) ; a bug in deb package (defun bm-lookup-mouse (event) (interactive "e") (require 'lookup) (require 'thingatpt) (mouse-set-point event) (let* ((word (thing-at-point 'word))) (if word (progn (lookup) (lookup-pattern word)) (lookup-suspend))))) (bm-init "help mode" (require 'bm-help) ;;;(require 'ehelp) ;; enable electric help mode ;;;(define-key global-map "\C-h" 'ehelp-command) ;;;(define-key global-map [help] 'ehelp-command) ;;;(define-key global-map [f1] 'ehelp-command) ) (bm-init "sawfish-mode" (autoload 'sawfish-mode "sawfish" "sawfish-mode" t) (setq auto-mode-alist (cons '("\\.sawfishrc$" . sawfish-mode) auto-mode-alist) auto-mode-alist (cons '("\\.jl$" . sawfish-mode) auto-mode-alist))) (bm-init "ilisp: a generalized (X)Emacs interface to an underlying Lisp system" (load "~/.ilisp")) (bm-init "GCL" (setq load-path (append '("/usr/lib/gcl/elisp/") load-path))) (defun hyperspec-lookup-read-symbol () (let* ((symbol-at-point (thing-at-point 'symbol)) (default (when (and symbol-at-point (intern-soft (downcase symbol-at-point) common-lisp-hyperspec-symbols)) symbol-at-point)) (prompt (concat "Look up symbol in Common Lisp HyperSpec: " (when default (format "(default %s) " default)))) (symbol (completing-read prompt common-lisp-hyperspec-symbols #'boundp t nil 'common-lisp-hyperspec-history))) (or (and (not (string= symbol "")) symbol) default (error "No symbol specified.")))) (defadvice hyperspec-lookup (around bmonkey activate preactivate) "Customized completing read." (interactive (list (hyperspec-lookup-read-symbol))) (require 'browse-url) ad-do-it) ;(let ((browse-url-browser-function 'browse-url-w3)) ; ad-do-it)) (ad-activate 'hyperspec-lookup) (bm-init "Info-mode" (unless emacs21 (setq Info-directory-list (let ((path (getenv "INFOPATH"))) (cond (path (split-string path path-separator)) ((and (boundp 'Info-default-directory-list) Info-default-directory-list)) (t '("/usr/info" "/usr/share/info"))))) ;;HACK Info emacs manual name hack (emacs -> emacs-e20). (autoload 'Info-find-node "info") (defadvice Info-find-node (before emacs-info-name-hack (filename nodename &optional no-going-back tryfile line)) "Convert info file name `emacs' to `emacs-e20'. The Emacs manual Info files have names like 'emacs-e20-1.gz', 'emacs-e20-2.gz',... in Debian GNU/Linux system (potato), but other documents seem to expect them to be `emacs-1.gz', `emacs-2.gz', ... So this advice convert 'emacs' to 'emacs-e20'. " (if filename (progn (let ((dir (file-name-directory filename)) (name (file-name-nondirectory filename))) (cond ((or (null name) (string-match "^emacs19" name) (string-match "^emacs-e20" name))) ; already ok ((string-match "^emacs\\(.*\\)" name) (setq filename (concat dir "emacs-e20" (match-string 1 name))))))))) (ad-activate 'Info-find-node))) (bm-init "Ediff" (defadvice ediff-documentation (around info-name-hack (&optional node) preactivate activate) "Display Ediff's manual. With optional NODE, goes to that node. BMONKEY: Changed Info file names to suite Debian system." (interactive) (let ((ctl-window ediff-control-window) (ctl-buf ediff-control-buffer)) (ediff-skip-unsuitable-frames) (condition-case nil (progn (pop-to-buffer (get-buffer-create "*info*")) (info (if ediff-xemacs-p "ediff-e20.info" "ediff-e20")) (if node (Info-goto-node node) (message "Type `i' to search for a specific topic")) (raise-frame (selected-frame))) (error (beep 1) (with-output-to-temp-buffer ediff-msg-buffer (princ ediff-BAD-INFO)) (if (window-live-p ctl-window) (progn (select-window ctl-window) (set-window-buffer ctl-window ctl-buf)))))))) (bm-init "Info-look" (defadvice info-lookup-symbol (around force-exact-match (symbol &optional mode)) "Force exact matching of a Info menu item. e.g. Prevent `push' in \"(cl)Function Index\" to be taken for `push-mark' in \"(elisp)Index\"." (let ((original-func (symbol-function 'Info-extract-menu-item))) (fset 'Info-extract-menu-item (lambda (menu-item) (setq menu-item (regexp-quote menu-item)) (let ((case-fold-search t)) (save-excursion (goto-char (point-min)) (or (search-forward "\n* menu:" nil t) (error "No menu in this node")) (or (re-search-forward (concat "\n\\* +" menu-item ":") nil t) ;;; prevent "push" in "(cl)top" to be taken for ;;; "push-mark" in "(elisp)top". ;;; similar cases would be rampant. ;;;(re-search-forward ;;; (concat "\n\\* +" menu-item) nil t) (error "No such item in menu")) (beginning-of-line) (forward-char 2) (Info-extract-menu-node-name))))) (unwind-protect ad-do-it (fset 'Info-extract-menu-item original-func)))) (ad-activate 'info-lookup-symbol)) (bm-init "man mode" (setq Man-notify-method 'bully)) (bm-init "jde-mode (Java development mode)" (autoload 'jde-mode "jde" "Major mode for developing Java applications and applets." t) (let ((alist auto-mode-alist)) (while alist (when (eq 'java-mode (cdar alist)) (setcdr (car alist) 'jde-mode)) (setq alist (cdr alist)))) (unless (rassq 'jde-mode auto-mode-alist) (setq auto-mode-alist (cons '("\\.java\\'" . jde-mode) auto-mode-alist)))) (bm-init "cperl-mode" (autoload 'perl-mode "cperl-mode" "alternate mode for editing Perl programs" t) (add-hook 'cperl-mode-hook #'(lambda () (setq indent-tabs-mode nil) (require 'perlplus) (require 'mode-compile) (define-key cperl-mode-map "\M-\t" 'perlplus-complete-symbol) (perlplus-setup) )) ;; self-insert-command hack. ;; Without this, "if" expands to ;; if ( -!-) { ;; } ;; which really should be, ;; if (-!-) { ;; } (mapcar #'(lambda (function) (ad-add-advice function (ad-make-advice 'canna-self-insert-command-hack ; name symbol of this advice nil ; protect? t ; enable? '(advice lambda () "Adjust `this-command'." (let ((this-command (if (memq this-command '(canna-self-insert-command canna-henkan-region-or-self-insert)) 'self-insert-command this-command))) ad-do-it))) 'around ; class 'first) ; position (ad-activate function)) '(cperl-electric-keyword cperl-electric-pod)) ;(setq cperl-hairy t) (setq cperl-indent-level 4 cperl-font-lock t cperl-electric-lbrace-space nil cperl-electric-parens nil cperl-electric-linefeed t cperl-electric-keywords nil cperl-info-on-command-no-prompt t cperl-clobber-lisp-bindings t cperl-lazy-help-time 1)) (bm-init "eldoc-mode" (require 'eldoc) (eldoc-add-command-completions "canna-" ; Japanese imput method "bm-" ; local command )) (bm-init "emacs-lisp-mode" (add-hook 'emacs-lisp-mode-hook #'(lambda () ;;;(show-paren-mode t) (setq indent-tabs-mode nil) ; don't use tabs for indentations (define-key emacs-lisp-mode-map [return] 'newline-and-indent) (eldoc-mode t)))) (bm-init "lisp-interaction-mode" (add-hook 'lisp-interaction-mode-hook #'(lambda () ;;;(show-paren-mode t) (define-key lisp-interaction-mode-map [return] 'newline-and-indent) (eldoc-mode t)))) (bm-init "c-mode: The C language mode" ;; see cc-vars.el (add-hook 'c-mode-common-hook #'(lambda () (c-set-style "stroustrup") ;(define-key c-mode-map [return] 'newline-and-indent) (c-toggle-auto-state t) (c-toggle-hungry-state t)))) (bm-init "psgml" (add-hook 'sgml-mode-hook #'(lambda () (mapcar #'(lambda (assoc) (define-key sgml-mode-map (car assoc) (cdr assoc))) '(("\C-j" . sgml-insert-element) ;("\M-f" . bm-search-html-forward-token) ;("\M-b" . bm-search-html-backward-token) ;("\C-ce" . sgml-describe-element-type) ;("\C-cac" . sgml-list-content-elements) ;("\C-cao" . sgml-list-occur-in-elements)))))) )) (setq indent-tabs-mode nil)) ; don't use tabs for indentations )) (bm-init "Bookmarks" (setq bookmark-sort-flag nil)) (bm-init "Browse URLs" (setq browse-url-netscape-program "communicator")) (bm-init "URL" (setq url-proxy-services '(("http" . "127.0.0.1:8080") ("ftp" . "127.0.0.1:8080")))) (bm-init "W3" (setq w3-default-stylesheet "~/.w3/user.css" w3-default-homepage "~/.netscape/default.html")) (bm-init "Emacs flavor init" (load "bm-emacs") (load (expand-file-name (concat "." (symbol-name bm-emacs-variant))) "MISSING-OK")) (bm-init "load-path clean up" (require 'bm-load-path) (let ((temp-buffer-show-function 'identity)) ; disable display (bm-load-path-remove-redundant-directories))) ; (bm-init "Pop up `bm-init-message-buffer-name' if error occured" ; (when (get-buffer bm-init-message-buffer-name) ; (switch-to-buffer-other-window (get-buffer bm-init-message-buffer-name)) ; (goto-char (point-min)))) ; (bm-init "update load-path database" ; (require 'bm-load-path-db);; load-path database update ; (bm-load-path-db-update bm-emacs-variant load-path)) (put 'narrow-to-region 'disabled nil) (put 'downcase-region 'disabled nil) (put 'upcase-region 'disabled nil)