[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/lisp/filesets.el
From: |
Juanma Barranquero |
Subject: |
[Emacs-diffs] Changes to emacs/lisp/filesets.el |
Date: |
Mon, 27 Jan 2003 03:44:28 -0500 |
Index: emacs/lisp/filesets.el
diff -c emacs/lisp/filesets.el:1.12 emacs/lisp/filesets.el:1.13
*** emacs/lisp/filesets.el:1.12 Sun Dec 15 20:47:06 2002
--- emacs/lisp/filesets.el Mon Jan 27 03:44:27 2003
***************
*** 163,169 ****
fsom-rv))
(defun filesets-some (fss-pred fss-lst)
! "Return non-nil if FSS-PRED is non-nil for any element of FSS-LST.
Like `some', return the first value of FSS-PRED that is non-nil."
(catch 'exit
(dolist (fss-this fss-lst nil)
--- 163,169 ----
fsom-rv))
(defun filesets-some (fss-pred fss-lst)
! "Return non-nil if FSS-PRED is non-nil for any element of FSS-LST.
Like `some', return the first value of FSS-PRED that is non-nil."
(catch 'exit
(dolist (fss-this fss-lst nil)
***************
*** 179,185 ****
(let ((fsm-test (or (plist-get fsm-keys ':test)
(function equal))))
(filesets-ormap (lambda (fsm-this)
! (funcall fsm-test fsm-item fsm-this))
fsm-lst)))
;(fset 'filesets-member 'member*) ;; or use the cl function
--- 179,185 ----
(let ((fsm-test (or (plist-get fsm-keys ':test)
(function equal))))
(filesets-ormap (lambda (fsm-this)
! (funcall fsm-test fsm-item fsm-this))
fsm-lst)))
;(fset 'filesets-member 'member*) ;; or use the cl function
***************
*** 199,205 ****
(let ((this (shell-command-to-string
(format "which --skip-alias %s 2> /dev/null | head -n 1"
cmd-list))))
! (if (equal this "")
nil
(file-name-nondirectory (substring this 0 (- (length this) 1))))))
--- 199,205 ----
(let ((this (shell-command-to-string
(format "which --skip-alias %s 2> /dev/null | head -n 1"
cmd-list))))
! (if (equal this "")
nil
(file-name-nondirectory (substring this 0 (- (length this) 1))))))
***************
*** 353,359 ****
(defcustom filesets-menu-cache-contents
'(filesets-be-docile-flag
filesets-submenus
! filesets-menu-cache
filesets-ingroup-cache)
"*Stuff we want to save in `filesets-menu-cache-file'.
--- 353,359 ----
(defcustom filesets-menu-cache-contents
'(filesets-be-docile-flag
filesets-submenus
! filesets-menu-cache
filesets-ingroup-cache)
"*Stuff we want to save in `filesets-menu-cache-file'.
***************
*** 745,751 ****
(:get-file-name (lambda (master file)
(filesets-which-file master
(concat file ".sty")
! (filesets-convert-path-list
(or (getenv "MY_TEXINPUTS")
(getenv "TEXINPUTS")))))))
((:name "Include")
--- 745,751 ----
(:get-file-name (lambda (master file)
(filesets-which-file master
(concat file ".sty")
! (filesets-convert-path-list
(or (getenv "MY_TEXINPUTS")
(getenv "TEXINPUTS")))))))
((:name "Include")
***************
*** 753,759 ****
(:get-file-name (lambda (master file)
(filesets-which-file master
(concat file ".tex")
! (filesets-convert-path-list
(or (getenv "MY_TEXINPUTS")
(getenv "TEXINPUTS"))))))
(:scan-depth 5))
--- 753,759 ----
(:get-file-name (lambda (master file)
(filesets-which-file master
(concat file ".tex")
! (filesets-convert-path-list
(or (getenv "MY_TEXINPUTS")
(getenv "TEXINPUTS"))))))
(:scan-depth 5))
***************
*** 763,769 ****
(:get-file-name (lambda (master file)
(filesets-which-file master
(concat file ".tex")
! (filesets-convert-path-list
(or (getenv "MY_TEXINPUTS")
(getenv "TEXINPUTS"))))))
(:scan-depth 5))
--- 763,769 ----
(:get-file-name (lambda (master file)
(filesets-which-file master
(concat file ".tex")
! (filesets-convert-path-list
(or (getenv "MY_TEXINPUTS")
(getenv "TEXINPUTS"))))))
(:scan-depth 5))
***************
*** 772,778 ****
(:get-file-name (lambda (master file)
(filesets-which-file master
(concat file ".bib")
! (filesets-convert-path-list
(or (getenv "MY_BIBINPUTS")
(getenv "BIBINPUTS")))))))))
("^.+\\.el$" t
--- 772,778 ----
(:get-file-name (lambda (master file)
(filesets-which-file master
(concat file ".bib")
! (filesets-convert-path-list
(or (getenv "MY_BIBINPUTS")
(getenv "BIBINPUTS")))))))))
("^.+\\.el$" t
***************
*** 1066,1072 ****
(fset 'filesets-add-submenu 'add-submenu))
(require 'easymenu)
!
(defun filesets-error (class &rest args)
"`error' wrapper."
(error (mapconcat 'identity args " ")))
--- 1066,1072 ----
(fset 'filesets-add-submenu 'add-submenu))
(require 'easymenu)
!
(defun filesets-error (class &rest args)
"`error' wrapper."
(error (mapconcat 'identity args " ")))
***************
*** 1122,1141 ****
(let ((files nil)
(dirs nil))
(dolist (this (file-name-all-completions "" dir))
! (cond
((string-match "^\\.+/$" this)
nil)
((string-match "[:/\\]$" this)
(when (or (not match-dirs-flag)
(not pattern)
(string-match pattern this))
! (filesets-message 5 "Filesets: matched dir %S with pattern %S"
this pattern)
(setq dirs (cons this dirs))))
(t
(when (or (not pattern)
(string-match pattern this))
! (filesets-message 5 "Filesets: matched file %S with pattern %S"
this pattern)
(setq files (cons (if full-flag
(concat (file-name-as-directory dir) this)
--- 1122,1141 ----
(let ((files nil)
(dirs nil))
(dolist (this (file-name-all-completions "" dir))
! (cond
((string-match "^\\.+/$" this)
nil)
((string-match "[:/\\]$" this)
(when (or (not match-dirs-flag)
(not pattern)
(string-match pattern this))
! (filesets-message 5 "Filesets: matched dir %S with pattern %S"
this pattern)
(setq dirs (cons this dirs))))
(t
(when (or (not pattern)
(string-match pattern this))
! (filesets-message 5 "Filesets: matched file %S with pattern %S"
this pattern)
(setq files (cons (if full-flag
(concat (file-name-as-directory dir) this)
***************
*** 1293,1299 ****
(filesets-get-external-viewer filename)))))
(when def
(filesets-alist-get def property nil t))))
!
(defun filesets-reset-filename-on-change ()
"Reset a buffer's filename if the buffer is being modified."
(when filesets-output-buffer-flag
--- 1293,1299 ----
(filesets-get-external-viewer filename)))))
(when def
(filesets-alist-get def property nil t))))
!
(defun filesets-reset-filename-on-change ()
"Reset a buffer's filename if the buffer is being modified."
(when filesets-output-buffer-flag
***************
*** 1530,1537 ****
(filesets-data-get entry ':ingroup nil t))
(defun filesets-file-open (open-function file-name &optional fileset-name)
! "Open FILE-NAME using OPEN-FUNCTION. If OPEN-FUNCTION is nil, it's
! value will be deduced from FILESET-NAME"
(let ((open-function (or open-function
(filesets-entry-get-open-fn fileset-name))))
(if (file-readable-p file-name)
--- 1530,1537 ----
(filesets-data-get entry ':ingroup nil t))
(defun filesets-file-open (open-function file-name &optional fileset-name)
! "Open FILE-NAME using OPEN-FUNCTION. If OPEN-FUNCTION is nil, its
! value will be deduced from FILESET-NAME."
(let ((open-function (or open-function
(filesets-entry-get-open-fn fileset-name))))
(if (file-readable-p file-name)
***************
*** 1573,1579 ****
(cond
((and (symbolp this) (fboundp this))
(let ((x (funcall this)))
! (setq rv (append rv (if (listp x) x (list x))))))
(t
(setq rv (append rv (list this))))))))
--- 1573,1579 ----
(cond
((and (symbolp this) (fboundp this))
(let ((x (funcall this)))
! (setq rv (append rv (if (listp x) x (list x))))))
(t
(setq rv (append rv (list this))))))))
***************
*** 1618,1624 ****
(or (equal mode ':ingroup)
(equal mode ':tree)))
(filesets-get-filelist fileset mode event)
! (filesets-get-filelist
(filesets-get-fileset-from-name name)
mode event))))
(when files
--- 1618,1624 ----
(or (equal mode ':ingroup)
(equal mode ':tree)))
(filesets-get-filelist fileset mode event)
! (filesets-get-filelist
(filesets-get-fileset-from-name name)
mode event))))
(when files
***************
*** 1644,1650 ****
(if (equal txt "") "" "
")
(format "%s" this))))))))
(cmd (concat fn " " args)))
! (filesets-cmd-show-result
cmd (shell-command-to-string cmd))))
((symbolp fn)
(let ((args
--- 1644,1650 ----
(if (equal txt "") "" "
")
(format "%s" this))))))))
(cmd (concat fn " " args)))
! (filesets-cmd-show-result
cmd (shell-command-to-string cmd))))
((symbolp fn)
(let ((args
***************
*** 1800,1806 ****
(cond
(inlist
(message "Filesets: '%s' is already in '%s'" this name))
! ((and (equal (filesets-entry-mode entry) ':files)
this)
(filesets-entry-set-files entry (cons this files) t)
(filesets-set-config name 'filesets-data filesets-data))
--- 1800,1806 ----
(cond
(inlist
(message "Filesets: '%s' is already in '%s'" this name))
! ((and (equal (filesets-entry-mode entry) ':files)
this)
(filesets-entry-set-files entry (cons this files) t)
(filesets-set-config name 'filesets-data filesets-data))
***************
*** 1911,1917 ****
(if (null (cdr x))
""
", "))))
! (setq rv
(concat
rv
(if filesets-menu-shortcuts-flag
--- 1911,1917 ----
(if (null (cdr x))
""
", "))))
! (setq rv
(concat
rv
(if filesets-menu-shortcuts-flag
***************
*** 2117,2123 ****
(append rv
(if files
`((,nm
! [,(concat "Inclusion Group: "
(file-name-nondirectory master))
(filesets-open ':ingroup ',master ',fsn)]
"---"
--- 2117,2123 ----
(append rv
(if files
`((,nm
! [,(concat "Inclusion Group: "
(file-name-nondirectory master))
(filesets-open ':ingroup ',master ',fsn)]
"---"
***************
*** 2127,2133 ****
(mapcar
(lambda (this)
(setq count (+ count 1))
! (let ((ff
(filesets-ingroup-collect-build-menu
fs (list this) count)))
(if (= (length ff) 1)
(car ff)
--- 2127,2133 ----
(mapcar
(lambda (this)
(setq count (+ count 1))
! (let ((ff
(filesets-ingroup-collect-build-menu
fs (list this) count)))
(if (= (length ff) 1)
(car ff)
***************
*** 2184,2190 ****
(let* ((x (file-name-as-directory x))
(xx (concat dir x))
(dd (filesets-build-dir-submenu-now
! (+ level 1) depth entry
lookup-name xx patt fd))
(nm (concat (filesets-get-shortcut count)
x)))
--- 2184,2190 ----
(let* ((x (file-name-as-directory x))
(xx (concat dir x))
(dd (filesets-build-dir-submenu-now
! (+ level 1) depth entry
lookup-name xx patt fd))
(nm (concat (filesets-get-shortcut count)
x)))
***************
*** 2206,2212 ****
(append
dirsmenu
filesmenu))
! (filesets-get-menu-epilog `(,dir ,patt) ':tree
lookup-name rebuild-flag)))
nil))
--- 2206,2212 ----
(append
dirsmenu
filesmenu))
! (filesets-get-menu-epilog `(,dir ,patt) ':tree
lookup-name rebuild-flag)))
nil))
***************
*** 2382,2388 ****
(with-temp-buffer
(dolist (this filesets-menu-cache-contents)
(if (get this 'custom-type)
! (progn
(insert (format "(setq-default %s '%S)" this (eval this)))
(when filesets-menu-ensure-use-cached
(newline)
--- 2382,2388 ----
(with-temp-buffer
(dolist (this filesets-menu-cache-contents)
(if (get this 'custom-type)
! (progn
(insert (format "(setq-default %s '%S)" this (eval this)))
(when filesets-menu-ensure-use-cached
(newline)
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] Changes to emacs/lisp/filesets.el,
Juanma Barranquero <=