Lisp error: (error "Recursive `require' for feature `compile'")
John Chandler <[email protected]> Thu, 9 Aug 2007 14:40:12 -0400
| Newsgroups | gmane.emacs.jdee |
|---|---|
| Message-ID | <[email protected]> |
GNU Emacs 22.0.97.1 (powerpc-apple-darwin8.9.0, Carbon Version 1.6.0)
of 2007-04-08 on g5.tokyo.stp.isas.jaxa.jp
jde-2.3.5.1
cedet-1.0pre4
Debugger entered--Lisp error: (error "Recursive `require' for feature `compile'")
require(compile)
byte-code(",A@A!,ABCDEFGFH&" [require compile custom-declare-group grep nil "Run grep as inferior of Emacs, parse error messages." :group tools processes] 8)
(grep-compute-defaults)
(progn (grep-compute-defaults) grep-command)
(or grep-command (progn (grep-compute-defaults) grep-command))
(lambda (symbol) (or grep-command (progn ... grep-command)))(grep-command)
custom-initialize-reset(grep-command nil)
custom-declare-variable(grep-command nil ("/usr/share/emacs/21.2/lisp/progmodes/compile.elc" . 1921) :type string :get (lambda (symbol) (or grep-command (progn ... grep-command))) :group compilation)
require(compile)
byte-code(",A@A!,ABCDEFGFH&" [require compile custom-declare-group grep nil "Run grep as inferior of Emacs, parse error messages." :group tools processes] 8)
(grep-compute-defaults)
(progn (grep-compute-defaults) grep-command)
(or grep-command (progn (grep-compute-defaults) grep-command))
(lambda (symbol) (or grep-command (progn ... grep-command)))(grep-command)
custom-initialize-reset(grep-command nil)
custom-declare-variable(grep-command nil ("/usr/share/emacs/21.2/lisp/progmodes/compile.elc" . 1921) :type string :get (lambda (symbol) (or grep-command (progn ... grep-command))) :group compilation)
require(compile)
byte-code(",A@A!,ABCDEFGFH&" [require compile custom-declare-group grep nil "Run grep as inferior of Emacs, parse error messages." :group tools processes] 8)
(grep-compute-defaults)
(progn (grep-compute-defaults) grep-command)
(or grep-command (progn (grep-compute-defaults) grep-command))
(lambda (symbol) (or grep-command (progn ... grep-command)))(grep-command)
custom-initialize-reset(grep-command nil)
custom-declare-variable(grep-command nil ("/usr/share/emacs/21.2/lisp/progmodes/compile.elc" . 1921) :type string :get (lambda (symbol) (or grep-command (progn ... grep-command))) :group compilation)
require(compile)
byte-code(",A@A!,ABCDEFGFH&" [require compile custom-declare-group grep nil "Run grep as inferior of Emacs, parse error messages." :group tools processes] 8)
(grep-compute-defaults)
(progn (grep-compute-defaults) grep-command)
(or grep-command (progn (grep-compute-defaults) grep-command))
(lambda (symbol) (or grep-command (progn ... grep-command)))(grep-command)
custom-initialize-reset(grep-command nil)
custom-declare-variable(grep-command nil ("/usr/share/emacs/21.2/lisp/progmodes/compile.elc" . 1921) :type string :get (lambda (symbol) (or grep-command (progn ... grep-command))) :group compilation)
require(compile)
eval-buffer(#<buffer *load*<2>> nil "/Users/jmc/tools/jde-2.3.5.1/lisp/jde-compile.el" nil t) ; Reading at buffer position 1427
load-with-code-conversion("/Users/jmc/tools/jde-2.3.5.1/lisp/jde-compile.el" "/Users/jmc/tools/jde-2.3.5.1/lisp/jde-compile.el" nil t)
require(jde-compile)
eval-buffer(#<buffer *load*> nil "/Users/jmc/tools/jde-2.3.5.1/lisp/jde.el" nil t) ; Reading at buffer position 2510
load-with-code-conversion("/Users/jmc/tools/jde-2.3.5.1/lisp/jde.el" "/Users/jmc/tools/jde-2.3.5.1/lisp/jde.el" nil t)
require(jde)
eval((require (quote jde)))
eval-last-sexp-1(nil)
eval-last-sexp(nil)
call-interactively(eval-last-sexp)
.emacs
(text/plain, 1.9 KB)
(defun ce:is-emacs18 ()
"Return t iff current version is some revision of emacs18."
(equal "18" (substring emacs-version 0 2)))
(defun ce:is-emacs19 ()
"Return t iff current version is some revision of emacs19."
(equal "19" (substring emacs-version 0 2)))
(defun ce:is-emacs20 ()
"Return t iff current version is some revision of emacs20."
(equal "20" (substring emacs-version 0 2)))
(defun ce:is-emacs21 ()
"Return t iff current version is some revision of emacs21."
(equal "21" (substring emacs-version 0 2)))
(defun ce:is-emacs22 ()
"Return t iff current version is some revision of emacs22."
(equal "22" (substring emacs-version 0 2)))
;;;
(if (ce:is-emacs18)
(load-file (expand-file-name "~jmc/.emacs18"))
)
(if (ce:is-emacs19)
(load-file (expand-file-name "~jmc/.emacs19"))
)
(if (ce:is-emacs20)
(load-file (expand-file-name "~jmc/.emacs20"))
)
(if (ce:is-emacs21)
(load-file (expand-file-name "~jmc/.emacs20"))
)
(if (ce:is-emacs22)
(load-file (expand-file-name "~jmc/.emacs20"))
)
;;;
(put 'upcase-region 'disabled nil)
(quietly-read-abbrev-file (expand-file-name "~jmc/.abbrevs"))
(put 'downcase-region 'disabled nil)
(defun upcase-regexp (reg)
(interactive "sRegexp: ")
(while (re-search-forward reg nil t nil)
(upcase-region (match-beginning 0) (match-end 0))))
(defun upcase-initials-regexp (reg)
(interactive "sRegexp: ")
(while (re-search-forward reg nil t nil)
(upcase-initials-region (match-beginning 0) (match-end 0))))
(put 'erase-buffer 'disabled nil)
(custom-set-variables
;; custom-set-variables was added by Custom -- don't edit or cut/paste it!
;; Your init file should contain only one such instance.
'(ange-ftp-ftp-program-args (quote ("-i" "-n" "-g" "-v" "-u")))
'(smtpmail-smtp-server "mail.bellsouth.net"))
(custom-set-faces
;; custom-set-faces was added by Custom -- don't edit or cut/paste it!
;; Your init file should contain only one such instance.
)
.emacs20
(text/plain, 26.8 KB)
;;; prevent opening new frames -- seems to corrupt something and
;;; cause crashes sometime later. -jmc 11 30 98
(defun new-frame () nil)
(setq user-full-name "John Chandler")
(put 'eval-expression 'disabled nil)
(set-variable 'inhibit-startup-message 't)
(setq max-lisp-eval-depth 500)
(put 'eval-expression 'disabled nil)
(put 'narrow-to-region 'disabled nil)
(setq load-path
(append (list (expand-file-name "/usr/share/emacs/21.2/lisp/progmodes")
(expand-file-name "~jmc/tools/lispbox/lispbox-0.4")
(expand-file-name "~jmc/tools/lispbox/lispbox-0.4/slime-1.2")
(expand-file-name "~jmc/.elisp")
(expand-file-name "~jmc/.elisp19")
;;; (expand-file-name "/usr/Local/share/emacs/site-lisp")
;; (expand-file-name "~jmc/tile/src")
)
load-path))
(setq exec-path (append exec-path (list "/local/lib/emacs/etc")))
(setq auto-mode-alist (append
'(("\\.txt$" . text-mode)
("\\.spec$" . text-mode)
("\\.card$" . text-mode)
("\\.pl$" . perl-mode)
("\\.py$" . python-mode)
("\\.bib$" . bibtex-mode)
("\\.t$" . scheme-mode)
("\\.tcl$" . tcl-mode)
("^[^.]*$" . text-mode))
auto-mode-alist))
(add-hook 'java-mode-hook 'turn-on-font-lock)
(add-hook 'c-mode-hook 'turn-on-font-lock)
(autoload 'python-mode "python-mode" )
(add-hook 'python-mode-hook 'turn-on-font-lock)
(setq text-mode-hook '(lambda () (auto-fill-mode 1)
;;; (define-global-abbrev "teh" "the")
;;; (define-global-abbrev "hte" "the")
;;; (define-global-abbrev "adn" "and")
;;; (define-global-abbrev "nad" "and")
(abbrev-mode 1)))
(setq outline-mode-hook '(lambda ()
(hide-body)
(local-set-key "\C-c\C-d" 'show-subtree)))
;;;(load "cc-mode")
;;;(setq c-mode-hook
;;; '(lambda ()
;;; (setq c-label-offset -1)
;;; (modify-syntax-entry ?_ "w" (syntax-table))
;;; (require 'sdk-c-indentation)))
;;;
(display-time)
(setq search-slow-window-lines 3)
(setq search-slow-speed 2400)
(setq truncate-partial-width-windows nil)
;; Provide machine identification in mode-line
(set-default 'mode-line-buffer-identification
(list (concat "[" (system-name) "]: %12b")))
;; much of this should be auto-loaded
(autoload 'ispell-word "ispell" "Check the spelling of a word" t)
(autoload 'ispell-buffer "ispell" "Check the spelling of the current buffer" t)
(autoload 'ispell-region "ispell" "Check the spelling of the region" t)
(autoload 'bibtex-mode "bibtex-mode" "Templates for bibtex." t)
(autoload 'c++-mode "c++-mode" "Set C++ Mode" t)
(autoload 'tcl-mode "tcl" "TCL mode" t)
;; Mail oriented stuff
;; (require 'smtpmail)
(setq send-mail-function 'smtpmail-send-it)
;;(setq smtp-default-server "smtp.charter.net")
;;(setq smtp-default-server "mail.brandx.net")
;;; JMC0912 (setq smtp-default-server "mail.labridge.com")
;;; jmc1025 (setq smtp-default-server "mail.labridge.com")
;;; jmc20040731 (setq smtp-default-server "mullet.labridge.com")
(setq smtp-default-server "mail.bellsouth.net")
;;;(setq smtp-default-server "smtp.we.mediaone.net")
(setq smtp-service "smtp")
(setq smtp-local-domain "musrum.com")
(setq smtp-debug-info nil)
(autoload 'smtpmail-send-it "smtpmail")
(setq user-full-name "John Chandler")
;;; vanilla version ...
;;; (setq send-mail-function 'smtpmail-send-it)
;;; make sendmail prompt before sending
(setq send-mail-function
(function
(lambda ()
(interactive)
(if (y-or-n-p "Really send? ")
;;; (sendmail-send-it)
(smtpmail-send-it)
(error "Send Aborted")))))
;;; At some point, check whether these make any difference --
;;; I think theyre misspelled (should be smtp-*). -jmc 2001 12 3
;;;(setq smtpmail-default-smtp-server "mail.brandx.net")
;; JMC 0912(setq smtpmail-default-smtp-server "mail.labridge.com")
(setq smtpmail-local-domain "musrum.com")
(setq mail-self-blind 't)
(setq mail-default-reply-to "[email protected]"
user-mail-address "[email protected]")
(setq mail-indent-string " | ")
(setq rmail-last-rmail-file (expand-file-name "~/mail/"))
;;; vm setup
(require 'vm)
;;; in vm.el, this might wanna be changed:
(setq vm-summary-format "%2n %a %-17.17F %3m %2d %h %z %3l/%-5c \"%s\"
")
;;; if you want to see your and timezone in the summary
;;; [jmc] Mon Jul 19 11:48:38 1993
(autoload 'vm "vm" "Start VM on your primary inbox." t)
(autoload 'vm-other-frame "vm" "Like `vm' but starts in another frame." t)
(autoload 'vm-visit-folder "vm" "Start VM on an arbitrary folder." t)
(autoload 'vm-visit-virtual-folder "vm" "Visit a VM virtual folder." t)
(autoload 'vm-mode "vm" "Run VM major mode on a buffer" t)
(autoload 'vm-mail "vm" "Send a mail message using VM." t)
(autoload 'vm-submit-bug-report "vm" "Send a bug report about VM." t)
(setq vm-folder-directory (expand-file-name "~jmc/vmail/"))
(setq dired-mail-reader 'vm)
(setq vm-visit-when-saving t)
(setq vm-mutable-windows "neither-nil-nor-t")
(setq vm-startup-with-summary "neither-nil-nor-t")
(setq vm-forwarding-subject-format "Fwd: %s")
(setq vm-forwarded-headers '("To:" "From:" "Subject:" ))
(setq vm-unforwarded-header-regexp nil )
;;;(setq vm-summary-uninteresting-senders "[email protected]\\|John Chandler")
(setq vm-summary-uninteresting-senders "[email protected]\\|jmc@.*[Ww]est.[Ss]un.[Cc][Oo][Mm]\\|John.Chandler@.*[Ww]est.[Ss]un.[Cc][Oo][Mm]")
(setq vm-frame-per-completion nil)
(setq vm-frame-per-composition nil)
(setq vm-frame-per-edit nil)
(setq vm-frame-per-folder nil)
(setq vm-frame-per-help nil)
(setq vm-frame-per-summary nil)
;; (setq vm-mutable-frames t)
(setq vm-raise-frame-at-startup nil)
(setq vm-netscape-program "mozilla")
(setq vm-mime-external-content-types-alist
'(
("text/html" "mozilla")
("image/gif" "xv")
("image/jpeg" "xv")
("image/tiff" "xv")
("video/mpeg" "mpeg_play")
("audio/x-pn-realaudio" "/usr/local/rvplayer5.0b3/rvplayer")
("audio/x-pn-realaudio-plugin" "/usr/local/rvplayer5.0b3/rvplayer")
("application/postscript" "/usr/local/bin/ghostview")
("video" "xanim")
)
)
;;;(setq vm-auto-folder-alist
;;; ((Subject
;;; (Status . (expand-file-name "~jmc/vmail/status"))
;;; )))
;;;
;;; hack for new sysV From conventions that will otherwise split
;;; messages where the included message begins
(setq vm-default-folder-type 'From_-with-Content-Length)
(setq vm-trust-From_-with-Content-Length t)
(setq vm-convert-folder-types t)
;;; jmc 2 1 94 change behavior of "x"
(define-key vm-mode-map "x" 'vm-expunge-folder)
(define-key vm-mode-map "X" 'vm-quit-no-change)
;;; jmc 9 22 1999
(setq vm-mime-base64-decoder-program "/usr/local/bin/base64-decode")
(setq vm-mime-base64-encoder-program "/usr/local/bin/base64-encode")
(setq mail-user-agent 'vm-user-agent)
;; setq is deprecated, but replace it with what?
(setq vm-mail-check-interval 300)
(setq vm-circular-folders t)
(load-file "~jmc/.emacs-pop")
(add-hook 'mail-setup-hook 'mail-abbrevs-setup)
;;; what is this? jmc 2001/12/1
(setq bookmark-save-flag 1)
(setq LaTeX-mode-hook
'(lambda ()
(require 'ispell)
(setq ispell-filter-hook "/local/bin/detex")
(setq ispell-filter-hook-args "-wln")))
(setq TeX-mode-hook
'(lambda ()
(require 'ispell)
(setq ispell-filter-hook "/local/bin/detex")
(setq ispell-filter-hook-args "-wn")))
;;; rcs interface stuff
;;;(require 'rcs)
;;;(if (not (memq 'rcs-hack-modeline find-file-hooks))
;;; (setq find-file-hooks (cons 'rcs-hack-modeline find-file-hooks)))
;;;
;;;(setq rcs-edit-mode 'text-mode)
;;;
;;;(setq rcs-shell-path "/bin/csh")
;;;
;;;(defun ci ()
;;; "RCS checkin current buffer."
;;; (interactive)
;;; (rcs-ci-buffer))
;;;
;;;(defun co ()
;;; "RCS checkout current buffer."
;;; (interactive)
;;; (rcs-co-buffer)
;;; (start-process "chmod" nil "chmod" "g+w" (buffer-file-name)))
;;;
;;;(defun rlog ()
;;; "Display RCS log for current buffer."
;;; (interactive)
;;; (rcs-show-log-buffer))
;;;
;;;(defun rdiff (arg)
;;; "Display RCS context diff for current buffer. Arg means do context diff."
;;; (interactive "P")
;;; (let ((rcs-diff-options (if arg "-c" "-qDnewversion")))
;;; (rcs-diff-buffer)))
;;;
;;;(defun rcs-show-log-file (fn)
;;; "Show the RCS log for FILE."
;;; (interactive "FFile to show log of: ")
;;; (if (not (has-rcs-file-p fn))
;;; (message (concat "No RCS file exists for " fn))
;;; (let ((buf (get-buffer-create (concat "# rcs log : " fn " #"))))
;;; (save-excursion
;;; (set-buffer buf)
;;; (erase-buffer)
;;; (message "Getting log for %s..." fn)
;;; (call-process
;;; rcs-shell-path nil buf nil "-c"
;;; (concat "cd "
;;; (expand-file-name
;;; (or (file-name-directory fn) ".")) "&& exec "
;;; (find-exec-command "sdklog" rcs-exec-path)
;;; " -z "
;;; (file-name-nondirectory fn)))
;;; (goto-char 1))
;;; (if (not rcs-use-other-win)
;;; (switch-to-buffer buf)
;;; (switch-to-buffer-other-window buf)
;;; (select-window (previous-window)))
;;; (message "Done"))))
;;; misc hacks
(defun 3-way ()
"Divide the screen into three windows, the way I normally work."
(interactive)
(split-window-vertically)
(enlarge-window (- (window-height) 9))
(split-window-horizontally))
(defun date ()
(interactive)
(message (current-time-string)))
(defun toggle-stack-error ()
(interactive)
(setq debug-on-error (not debug-on-error))
(message "Debug on error set to: %s" debug-on-error))
;; shell-set-directory needs some work VERY badly (+n argument totally ignored
(setq shell-popd-regexp "popd\\|po[+0-9]*")
(setq shell-pushd-regexp "pushd\\|x[+0-9]*")
;;; (load-file "~sdk/.emacs-bindings") ;; I've inlined this for jmc
;;;;;;;;;;;;;;;;
;; get rid of stupid bindings
(global-unset-key "\C-x\C-n") ;; goal columns
(global-unset-key "\C-x\C-l") ;; lower case region
(global-unset-key "\C-x\C-u") ;; upcase region
;;;;;;;;;;;;;;;;
;; do something useful with the backspace key
(global-set-key "\C-h" 'backward-delete-char-untabify)
(global-set-key "\C-?" 'backward-delete-char-untabify)
(global-set-key "\M-\C-h" 'backward-kill-word)
;;;;;;;;;;;;;;;;
;; Provide reasonable window switching commands
(fset 'prev-window
"-1o")
(global-set-key "\C-xp" 'prev-window)
(global-set-key "\C-xn" 'other-window)
;;;;;;;;;;;;;;;;
;; Provide mechanism for single line scrolling
(fset 'scroll-down-1 "1v")
(fset 'scroll-up-1 "1")
(global-set-key "\M-p" 'scroll-down-1)
(global-set-key "\M-n" 'scroll-up-1)
;;;;;;;;;;;;;;;;
;; compile
(autoload 'mode-compile "mode-compile"
"Command to compile current buffer file dependently of the major mode" t)
(global-set-key "\C-cc" 'mode-compile)
(autoload 'mode-compile-kill "mode-compile"
"Command to kill a compilation launched by `mode-compile'" t)
(global-set-key "\C-ck" 'mode-compile-kill)
;; misc
;;(global-set-key "\M-/" 'loop-word)
(global-set-key "\C-x'" 'goto-fspec)
(global-set-key "\C-cs" 'toggle-stack-error)
(global-set-key "\e$" 'ispell-word)
(global-set-key "\C-\\" 'mode-compile)
(global-set-key "\C-xt" '(lambda ()
(interactive)
(set-variable 'truncate-lines
(not truncate-lines))))
(global-set-key "\C-x?" 'help-for-help)
(global-set-key "\M-\C-r" 'isearch-backward-regexp)
;;;;;;;;;;;;;;;;
;; experimental
;;;;;;;;;;;;;;;;
(load-file "~jmc/.emacs-gnus")
(setq gnus-user-full-name "Skeezix")
;;; not emacs19
;;;(load-file "~jmc/.emacs-dired-x")
;;;;;;;;;;;;;;;;
;; Swap tab & space in minibuffer completion maps
(define-key minibuffer-local-completion-map " " 'minibuffer-complete)
(define-key minibuffer-local-completion-map " " 'minibuffer-complete-word)
(define-key minibuffer-local-must-match-map " " 'minibuffer-complete)
(define-key minibuffer-local-must-match-map " " 'minibuffer-complete-word)
;;(message "give me a break")
(yow)
;; (x-set-foreground-color "white")
;; (x-set-background-color "midnight blue")
;; (x-set-cursor-color "magenta")
;; (x-set-mouse-color "cyan")
;;(setq shell-mode-hook
;; '(lambda ()
;; (require 'filename-expansion)
;; (local-set-key "\t" 'shell-expand-file-name)))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; Experimental garbage
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defvar saved-window-configuration nil "Save screen layout")
(defun save-window-state ()
(interactive)
(setq saved-window-configuration (current-window-configuration))
(message "Window configuration saved..."))
(defun restore-window-state ()
(interactive)
(if saved-window-configuration
(set-window-configuration saved-window-configuration)
(message "No saved window state.")))
(global-set-key "\C-cW" 'save-window-state)
(global-set-key "\C-cw" 'restore-window-state)
(defun sdk-list-buffers (arg)
"Like list-buffers but display in *this* window dammit."
(interactive "P")
(switch-to-buffer "*Buffer List*")
(list-buffers arg)
(beginning-of-buffer))
(global-set-key "\C-x\C-b" 'sdk-list-buffers)
(fset 'Buffer-menu-save-and-delete
"ds")
(define-key Buffer-menu-mode-map "D" 'Buffer-menu-save-and-delete)
(defun timestamp ()
"Insert timestamp (+userid) into current buffer at point."
(interactive)
(insert (format "[%s] " (user-login-name)) (date)))
(defun xdvi ()
"Runs xdvi on the current buffer's dvi file."
(interactive)
(let ((name (file-name-nondirectory (buffer-file-name))))
(start-process "xdvi" nil "xdvi"
(concat (substring name 0 (string-match "[.]tex" name))
".dvi"))))
(defun idraw ()
"Runs idraw in the current buffers directory."
(interactive)
(start-process "idraw" nil "idraw"))
(defun dvips ()
"Runs dvips on the current buffer's dvi file."
(interactive)
(let ((name (file-name-nondirectory (buffer-file-name))))
(start-process "dvips" nil "dvips"
(substring name 0 (string-match "[.]tex" name)))))
;;;(setq inferior-lisp-program "/s/cscw/bin/xt")
;;;(setq scheme-program-name "/s/cscw/bin/xt")
;;;(setq scheme-program-arguments "-h 1000000")
(setq scheme-program-name (expand-file-name "/usr/local/bin/scsh"))
;;;
;;;(defun lpr (images-per-page &optional start end)
;;; "Print the current buffer with Twin Sun tools."
;;; (interactive "P")
;;; (setq images-per-page (or images-per-page 4))
;;; (setq start (or start (point-min)))
;;; (setq end (or end (point-max)))
;;; (shell-command-on-region
;;; start end
;;; (format "/local/bin/psf -xH '%s' -%d | lpr -P%s"
;;; (buffer-name)
;;; images-per-page
;;; (or (getenv "PRINTER") "aleph"))))
;;;
;;;(defun lpr-region (images-per-page start end)
;;; (interactive "P\nr")
;;; (lpr images-per-page start end))
;;;
;;;(defun lpr-buffer (images-per-page)
;;; (interactive "P")
;;; (lpr images-per-page))
;;;
;;;(defun lpq ()
;;; "Check status of printers."
;;; (interactive)
;;; (shell-command (format "lpq -P%s" (or (getenv "PRINTER") "aleph"))))
;;;
(defun lpr (images-per-page &optional start end)
"Print the current buffer with NON-Twin Sun tools. (2-up,landscape)"
(interactive "P")
(setq images-per-page (or images-per-page 2))
(setq start (or start (point-min)))
(setq end (or end (point-max)))
(shell-command-on-region
start end
(format "/net/suntools.eng/export/tools/sparc/bin/enscript -B -r -P%s -%d "
(or (getenv "PRINTER") "adm-q")
images-per-page
)))
(defun lpR (images-per-page &optional start end)
"Print the current buffer with NON-Twin Sun tools. (1-up, portrait)"
(interactive "P")
(setq images-per-page (or images-per-page 1))
(setq start (or start (point-min)))
(setq end (or end (point-max)))
(shell-command-on-region
start end
(format "/net/suntools.eng/export/tools/sparc/bin/enscript -B -R -P%s -%d "
(or (getenv "PRINTER") "adm-q")
images-per-page
)))
(defun lpr-region (images-per-page start end)
"Print the marked region with NON-Twin Sun tools. (2-up,landscape)"
(interactive "P\nr")
(lpr images-per-page start end))
(defun lpR-region (images-per-page start end)
"Print the marked region with NON-Twin Sun tools. (1-up, portrait)"
(interactive "P\nr")
(lpR images-per-page start end))
(defun lpr-buffer (images-per-page)
"Print the current buffer with NON-Twin Sun tools. (2-up,landscape)"
(interactive "P")
(lpr images-per-page))
(defun lpq ()
"Check status of printers."
(interactive)
(shell-command (format "lpq -P%s" (or (getenv "PRINTER") "lorlp-q"))))
(defun template-cscw ()
"Template for sending a message in mail that can be executed to view
a particular node."
(interactive)
(insert "(progn (cscw-info) (Info-goto-node <node>))"))
(defun x-store-text (&optional ignore)
"Store the contents of the x cut buffer into the current buffer at
location of point."
(interactive)
(insert (x-get-cut-buffer)))
;;; emacs19 version, without mouse.
(defun sdk-x-setup ()
(if (eq window-system 'x)
(progn
(setq visible-bell t)
(setq mode-line-inverse-video nil)
;;; (define-key mouse-map x-button-s-left 'x-cut-text)
;;; (define-key mouse-map x-button-s-left-up nil)
;;; (define-key mouse-map x-button-s-middle 'x-store-text)
;;; (define-key mouse-map x-button-s-middle-up nil)
)
(global-set-key "" (quote set-mark-command))
))
(setq term-setup-hook 'sdk-x-setup)
(defun rcs-occur ()
"Entries in dired that are likely to be checked out by me."
(interactive)
;; (occur "-rw-rw-r-- +[0-9]* +sdk.+[.][ch]$" nil)
(shell-command "agrep \"[0-9]; strict;\" RCS/*"))
(require 'etags)
(defun goto-fspec ()
"Look for an fspec/line number pair under the point and go to
that file/line in another window."
(interactive)
(let (fspec)
(save-excursion
(re-search-backward "^\\| ")
(setq fspec
(ce:parse-string "\\(.+\\):\\([0-9]+\\):"
(ce:matched-string "[^ \t]*:[0-9]+:"))))
(find-file-other-window (nth 1 fspec))
(goto-line (read (nth 2 fspec)))))
(defun tail (file)
"Run tail -f on specified file in emacs buffer."
(interactive "fFile: ")
(let ((buf (generate-new-buffer
(concat "tail==>" (file-name-nondirectory file)))))
;; (start-process "tail" buf "/usr/ucb/tail" "-f" file)
(start-process "tail" buf "/usr/bin/tail" "-f" file)
(switch-to-buffer-other-window buf)))
;;; maybe this will work better ...
(defun mytail (file)
"Run tail -f on specified file in emacs buffer."
(interactive "fFile: ")
(setq absfile (expand-file-name file))
(let ((buf (generate-new-buffer
(concat "tail==>" (file-name-nondirectory absfile)))))
;; (start-process "tail" buf "/usr/ucb/tail" "-f" absfile)
(start-process "tail" buf "/usr/bin/tail" "-f" absfile)
(switch-to-buffer-other-window buf)))
;;================
;; this is where sdk-c-indentation used to be
;; [jmc] Tue Apr 26 18:44:44 1994
(defun count-lines-in-current-buffer ()
(interactive)
(let ((lines (count-lines (point-min) (point-max))))
(if (interactive-p)
(let ((plines (count-lines (point-min) (point))))
(message "Buffer has %s lines (%s + %s)"
lines plines (- lines plines)))
lines)))
(global-set-key "\C-xl" 'count-lines-in-current-buffer)
;;; ange or efs
(load-file "~jmc/.emacs-ange")
;; (load-file "~jmc/.emacs-efs")
;;; get the color name on the current line and set the foreground or
;;; background color.
;;;
;; (fset 'fg
;; "ææææâ÷øset-for
")
;; (fset 'bg
;; "ææææâ÷øset-back
")
;; (fset 'sum-3-and-insert
;; "æææ÷(insert (int-to-string (+ ) ) \" \")
")
;;
(defalias 'bg (read-kbd-macro
"C-a 4*M-f M-b C-SPC C-e M-w M-x set-ba SPC RET C-y RET"))
(defalias 'fg (read-kbd-macro
"C-a 4*M-f M-b C-SPC C-e M-w M-x set-fore SPC RET C-y RET"))
;; bind these to some pair of keys in the rgb.txt buffer.
(fset 'foreground-color-cruise
[?\M-x ?f ?g return ?\C-n])
(fset 'background-color-cruise
[?\M-x ?b ?g return ?\C-n])
;;;;;;;;;;;;;;;;
;; Swap tab & space in minibuffer completion maps
(define-key minibuffer-local-completion-map " " 'minibuffer-complete)
(define-key minibuffer-local-completion-map " " 'minibuffer-complete-word)
(define-key minibuffer-local-must-match-map " " 'minibuffer-complete)
(define-key minibuffer-local-must-match-map " " 'minibuffer-complete-word)
(setq auto-save-directory
(concat "/usr/etmp/autosave/" (user-login-name)))
(require 'auto-save)
;; *** TILE forth mode ***
(setq forth-help-load-path '("~/tile/doc"))
(autoload 'forth-mode "forth" "forth-mode" t)
(setq auto-mode-alist
(append '(("\\.f83$" . forth-mode))
auto-mode-alist))
;;; removed "("\\.tst$" . forth-mode)" from above jmc 1 28 99
(defun replace-numerically (in out)
"Replace occurances of regexp IN with the format string OUT. If
format contains the characters '%d' then out will contain that number
of the replacement at that location."
(interactive "sReplace Regexp: \nswith format: ")
(save-excursion
(let ((n 0))
(while (re-search-forward in nil t)
(setq n (1+ n))
(replace-match (format out n) nil 'literal)))))
;;; e.g., (replace-numerically "^ *[0-9]+\\." "%2.d.")
;;; to re-order " 1.", ... "10.","11.".
;;; set tab-width to 4
(fset 't4
"øsete-vear
tab w
4
")
;;; set some keys
(global-set-key "\M-r" 'bury-buffer)
;;; the following is req'd (by me) for Carbon Emacs, and may only work on Emacs22+
(define-key minibuffer-local-filename-completion-map " " 'minibuffer-complete)
;;; crypt
(require 'crypt++)
;; desktop.el stuff
(load "desktop")
(desktop-load-default)
;;;(desktop-read)
(fset 'crosswd
"grep \"^$\" words")
(autoload 'itelnet "itelnet" "telnet thru sun-barr" t)
(defun fix-stupid-line-wrapping (arg)
"Fix lame auto-line-wraps done by Netscape, et. al."
(interactive "p")
(query-replace-regexp "
\\([^>]\\)" " \\1" nil)
)
(defun scroll-both-windows (lines)
"Scroll both windows up.
For more details, see the documentation for `scroll-other-window'."
(interactive "P")
(scroll-other-window lines)
(scroll-up lines))
(global-set-key "\C-xw" 'scroll-both-windows )
;;; add a convenience key to buffer-menu-mode
(define-key Buffer-menu-mode-map "b" 'Buffer-menu-bury)
(defun Buffer-menu-bury ()
"Bury the buffer listed on this line."
(interactive)
(beginning-of-line)
(if (looking-at " [-M]") ;header lines
(ding)
(save-excursion
(beginning-of-line)
(bury-buffer (Buffer-menu-buffer t))
(let ((line (buffer-substring (point) (progn (forward-line 1) (point))))
(buffer-read-only nil))
(delete-region (point) (progn (forward-line -1) (point)))
(goto-char (point-max))
(insert line))
(message "Buried buffer moved to the end"))))
;;; (set-background-color "dark slate gray")
;;; (set-foreground-color "lemon chiffon")
(set-face-foreground (quote highlight) "black")
(set-face-foreground (quote region) "yellow")
(set-face-background (quote region) "black")
(set-mouse-color "red")
(fset 'shell-exec-current-line
[?\C-a ?\C-x ?/ return ?\C- ?\C-e ?\M-w escape ?> ?\C-y return ?\C-x ?j return ?\C-n])
;;; ********************
;;; WWW browsing using Netscape
;;;
(message "customizing ... www browser")
(setq browse-url-netscape-command "mozilla"
highlight-headers-follow-url-netscape-auto-raise nil
highlight-headers-follow-url-netscape-new-window t
browse-url-netscape-arguments (list "-ncols 48"))
(setq vm-url-browser 'vm-mouse-send-url-to-netscape
vm-netscape-program browse-url-netscape-command
vm-netscape-program-switches browse-url-netscape-arguments)
;;; Emacs-w3 configuration options
;;; already done above (setq load-path (cons (expand-file-name "~jmc/.elisp") load-path))
(autoload 'w3-preview-this-buffer "w3" "WWW Previewer" t)
(autoload 'w3-follow-url-at-point "w3" "Find document at pt" t)
(autoload 'w3 "w3" "WWW Browser" t)
(autoload 'w3-open-local "w3" "Open local file for WWW browsing" t)
(autoload 'w3-fetch "w3" "Open remote file for WWW browsing" t)
(autoload 'w3-use-hotlist "w3" "Use shortcuts to view WWW docs" t)
(autoload 'w3-show-hotlist "w3" "Use shortcuts to view WWW docs" t)
(autoload 'w3-follow-link "w3" "Follow a hypertext link." t)
(autoload 'w3-batch-fetch "w3" "Batch retrieval of URLs" t)
(autoload 'url-get-url-at-point "url" "Find the url under the cursor" nil)
(autoload 'url-file-attributes "url" "File attributes of a URL" nil)
(autoload 'url-popup-info "url" "Get info on a URL" t)
(autoload 'url-retrieve "url" "Retrieve a URL" nil)
(autoload 'url-buffer-visiting "url" "Find buffer visiting a URL." nil)
(autoload 'gopher-dispatch-object "gopher" "Fetch gopher dir" t)
;;; End of Emacs-w3 configuration options
(set-variable (quote dired-dwim-target) t)
(menu-bar-mode nil)
(tool-bar-mode nil)
;;; This function finds a file whose name relative to the buffer's current
;;; path occupies the entire line. E.g., the output of find on "." in a
;;; dired buffer.
(fset 'find-this-lines-file
[?\C-a ?\C- ?\C-e ?\M-w ?\C-x ?\C-f ?\C-y return])
(fset 'fix-dos-newlines
[?\M-x ?q ?u ?e return ?\C-q ?\C-m ?\C-q ?\C-j return ?\C-q ?\C-j return ?!])
(fset 'vm-this-lines-file
[?\C-e ?\C- ?\C-r ? ?\C-f ?\M-w ?\C-x ?/ ?` escape ?< ?\C-e ?\C-b ?\C- ?\C-r ? ?\C-f ?\M-w ?\C-x ?j ?` ?\M-x ?v ?m ?- ?s backspace ?v ? ?s ? ?f ? return ?\C-y ?\C-y ?\M-y ?\C-x ?\C-x ?/ ?\C-e return])
;; convert spaces in the name of this line's file to underscores
;; uses a buffer with a name, "changes". This should probably be avoided somehow.
(fset 'dired-filename-spaces-to-unders
[?\C- ?\C-e ?\M-w ?\C-x ?b ?c ?h ?a ?n ?g ?e ?s ?\C-m ?\C-[ ?> ?\C-y ?\C-a ?\M-x ?q ?u ?e ?\C-m ? ?\C-m ?_ ?\C-m ?! ?\C-a ?\C- ?\C-e ?\M-w ?\C-n ?\C-x ?b ?\C-m ?R ?\C-y ?\C-m ?\C-n])
(if window-system (mouse-avoidance-mode 'animate))
;;; HACHETTE, R.I.P. ;; (require 'hachette)
;;; HACHETTE, R.I.P. ;; ;;(setq hachette-proxy-port 8080 )
;;; HACHETTE, R.I.P. ;; ;;(setq hachette-proxy-host "lasc-cache.west" )
;;; HACHETTE, R.I.P. ;; (global-set-key (quote [f9]) (quote hachette-fetch-word-at-point))
(require 'ibuffer)
;;; (global-set-key "\C-x\C-b" (quote ibuffer))
(require 'vc-hooks)
(require 'vc)
(add-hook 'diary-hook 'appt-make-list)
(diary 0)
(defun reverse-string (s)
(apply 'string (reverse (string-to-list s))))
(defun f/ (x y)
(/ (float x) y))
(fset 'make-tag-pair
"\C-a<\C-k\C-y></\C-?\C-?\C-m</\C-y>\C-a\C-o")
(load "lispbox")
(defun c->f (c)
(- (/ (float (* 9 (+ c 40))) 5) 40))
(defun f->c (f)
(- (/ (float (* 5 (+ f 40))) 9) 40))
(load-file (expand-file-name "~jmc/.emacs-cdet"))
(load-file (expand-file-name "~jmc/tools/elib-1.0/elib-startup.el"))
(load-file (expand-file-name "~jmc/.emacs-jdee"))
.emacs-cdet
(text/plain, 1002 B)
;; Load CEDET ;;(load-file "~/cedet-VERSION/common/cedet.el") (load-file "~/tools/cedet-1.0pre4/common/cedet.elc") ;; Enabling various SEMANTIC minor modes. See semantic/INSTALL for more ideas. ;; Select one of the following: ;; * This enables the database and idle reparse engines ;;(semantic-load-enable-minimum-features) ;; * This enables some tools useful for coding, such as summary mode ;; imenu support, and the semantic navigator (semantic-load-enable-code-helpers) ;; * This enables even more coding tools such as the nascent intellisense mode ;; decoration mode, and stickyfunc mode (plus regular code helpers) ;; (semantic-load-enable-guady-code-helpers) ;; * This turns on which-func support (Plus all other code helpers) ;; (semantic-load-enable-excessive-code-helpers) ;; This turns on modes that aid in grammar writing and semantic tool ;; development. It does not enable any other features such as code ;; helpers above. ;; (semantic-load-enable-semantic-debugging-helpers)
.emacs-jdee
(text/plain, 320 B)
(add-to-list 'load-path (expand-file-name "~/emacs/site/jde/lisp")) ;; following two are handled in .emacs-cdet ;;(add-to-list 'load-path (expand-file-name "~/emacs/site/cedet/common")) ;;(load-file (expand-file-name "~/emacs/site/cedet/common/cedet.el")) (add-to-list 'load-path (expand-file-name "~/emacs/site/elib"))