/[emacs]/emacs/lisp/pcvs-parse.el
ViewVC logotype

Diff of /emacs/lisp/pcvs-parse.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.11 by monnier, Sun Mar 17 20:48:14 2002 UTC revision 1.11.2.1 by miles, Fri Apr 4 06:20:10 2003 UTC
# Line 1  Line 1 
1  ;;; pcvs-parse.el --- the CVS output parser  ;;; pcvs-parse.el --- the CVS output parser
2    
3  ;; Copyright (C) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000  Free Software Foundation, Inc.  ;; Copyright (C) 1991,92,93,94,95,96,97,98,99,2000,2002
4    ;;               Free Software Foundation, Inc.
5    
6  ;; Author: Stefan Monnier <monnier@cs.yale.edu>  ;; Author: Stefan Monnier <monnier@cs.yale.edu>
7  ;; Keywords: pcl-cvs  ;; Keywords: pcl-cvs
# Line 201  The remaining KEYS are passed directly t Line 202  The remaining KEYS are passed directly t
202    "Table of message objects for `cvs-parse-process'."    "Table of message objects for `cvs-parse-process'."
203    (let (c file dir path type base-rev subtype)    (let (c file dir path type base-rev subtype)
204      (cvs-or      (cvs-or
205        
206       (cvs-parse-status)       (cvs-parse-status)
207       (cvs-parse-merge)       (cvs-parse-merge)
208       (cvs-parse-commit)       (cvs-parse-commit)
# Line 210  The remaining KEYS are passed directly t Line 211  The remaining KEYS are passed directly t
211       ;; such duplicate info and luckily the second info is the one we want.       ;; such duplicate info and luckily the second info is the one we want.
212       ;; (and (cvs-match "M \\(.*\\)$" (path 1))       ;; (and (cvs-match "M \\(.*\\)$" (path 1))
213       ;;      (cvs-parse-merge path))       ;;      (cvs-parse-merge path))
214        
215       ;; Normal file state indicator.       ;; Normal file state indicator.
216       (and       (and
217        (cvs-match "\\([MARCUPNJ?]\\) \\(.*\\)$" (c 1) (path 2))        (cvs-match "\\([MARCUPNJ?]\\) \\(.*\\)$" (c 1) (path 2))
# Line 265  The remaining KEYS are passed directly t Line 266  The remaining KEYS are passed directly t
266         ;; [-n update] A new (or pruned) directory appeared but isn't traversed         ;; [-n update] A new (or pruned) directory appeared but isn't traversed
267         (and         (and
268          (cvs-match "New directory `\\(.*\\)' -- ignored$" (dir 1))          (cvs-match "New directory `\\(.*\\)' -- ignored$" (dir 1))
269          (cvs-parsed-fileinfo 'MESSAGE " " (file-name-as-directory dir)))          ;; (cvs-parsed-fileinfo 'MESSAGE " " (file-name-as-directory dir))
270            (cvs-parsed-fileinfo '(NEED-UPDATE . NEW-DIR) dir))
271    
272         ;; File removed, since it is removed (by third party) in repository.         ;; File removed, since it is removed (by third party) in repository.
273         (and         (and
274          (cvs-or          (cvs-or
275           (cvs-match "warning: \\(.*\\) is not (any longer) pertinent$" (file 1))           (cvs-match "warning: \\(.*\\) is not (any longer) pertinent$" (file 1))
276           (cvs-match "\\(.*\\) is no longer in the repository$" (file 1)))           (cvs-match "\\(.*\\) is no longer in the repository$" (file 1)))
277          (cvs-parsed-fileinfo 'DEAD file))          (cvs-parsed-fileinfo
278             (if dont-change-disc '(NEED-UPDATE . REMOVED) 'DEAD) file))
279    
280         ;; [add]         ;; [add]
281         (and         (and
# Line 285  The remaining KEYS are passed directly t Line 288  The remaining KEYS are passed directly t
288         (and         (and
289          (cvs-match "\\(.*\\), version \\(.*\\), resurrected$"          (cvs-match "\\(.*\\), version \\(.*\\), resurrected$"
290                     (path 1) (base-rev 2))                     (path 1) (base-rev 2))
291            ;; FIXME: resurrection only brings back the original version,
292            ;; not the latest on the branch, so `up-to-date' is not always
293            ;; what we want.
294          (cvs-parsed-fileinfo '(UP-TO-DATE . RESURRECTED) path nil          (cvs-parsed-fileinfo '(UP-TO-DATE . RESURRECTED) path nil
295                               :base-rev base-rev))                               :base-rev base-rev))
296    
# Line 306  The remaining KEYS are passed directly t Line 312  The remaining KEYS are passed directly t
312                                   'MISSING                                   'MISSING
313                                 '(UP-TO-DATE . UPDATED))                                 '(UP-TO-DATE . UPDATED))
314                               path))                               path))
315        
316         ;; Mode conflicts (rather than contents)         ;; Mode conflicts (rather than contents)
317         (and         (and
318          (cvs-match "conflict: ")          (cvs-match "conflict: ")
# Line 328  The remaining KEYS are passed directly t Line 334  The remaining KEYS are passed directly t
334           (cvs-match "sticky tag .* for file `\\(.*\\)' is not a branch$"           (cvs-match "sticky tag .* for file `\\(.*\\)' is not a branch$"
335                      (file 1)))                      (file 1)))
336          (cvs-parsed-fileinfo 'MESSAGE file))          (cvs-parsed-fileinfo 'MESSAGE file))
337        
338         ;; File unknown.         ;; File unknown.
339         (and (cvs-match "use `.+ add' to create an entry for \\(.*\\)$" (path 1))         (and (cvs-match "use `.+ add' to create an entry for \\(.*\\)$" (path 1))
340              (cvs-parsed-fileinfo 'UNKNOWN path))              (cvs-parsed-fileinfo 'UNKNOWN path))
# Line 346  The remaining KEYS are passed directly t Line 352  The remaining KEYS are passed directly t
352               'MESSAGE "" " "               'MESSAGE "" " "
353               "*** Add (setq cvs-execute-single-dir t) to your .emacs ***               "*** Add (setq cvs-execute-single-dir t) to your .emacs ***
354          See the FAQ file or the variable's documentation for more info."))          See the FAQ file or the variable's documentation for more info."))
355          
356         ;; Cvs waits for a lock.  Ignored: already handled by the process filter         ;; Cvs waits for a lock.  Ignored: already handled by the process filter
357         (cvs-match "\\[..:..:..\\] \\(waiting for\\|obtained\\) .*lock in .*$")         (cvs-match "\\[..:..:..\\] \\(waiting for\\|obtained\\) .*lock in .*$")
358         ;; File you removed still exists.  Ignore (will be noted as removed).         ;; File you removed still exists.  Ignore (will be noted as removed).
# Line 354  The remaining KEYS are passed directly t Line 360  The remaining KEYS are passed directly t
360         ;; just a note         ;; just a note
361         (cvs-match "use '.+ commit' to \\sw+ th\\sw+ files? permanently$")         (cvs-match "use '.+ commit' to \\sw+ th\\sw+ files? permanently$")
362         ;; [add,status] followed by a more complete status description anyway         ;; [add,status] followed by a more complete status description anyway
363         (cvs-match "nothing known about .*$")         (and (cvs-match "nothing known about \\(.*\\)$" (path 1))
364                (cvs-parsed-fileinfo 'DEAD path 'trust))
365         ;; [update] problem with patch         ;; [update] problem with patch
366         (cvs-match "checksum failure after patch to .*; will refetch$")         (cvs-match "checksum failure after patch to .*; will refetch$")
367         (cvs-match "refetching unpatchable files$")         (cvs-match "refetching unpatchable files$")
# Line 362  The remaining KEYS are passed directly t Line 369  The remaining KEYS are passed directly t
369         (cvs-match "Rebuilding administrative file database$")         (cvs-match "Rebuilding administrative file database$")
370         ;; ???         ;; ???
371         (cvs-match "--> Using per-directory sticky tag `.*'")         (cvs-match "--> Using per-directory sticky tag `.*'")
372        
373         ;; CVS is running a *info program.         ;; CVS is running a *info program.
374         (and         (and
375          (cvs-match "Executing.*$")          (cvs-match "Executing.*$")
# Line 374  The remaining KEYS are passed directly t Line 381  The remaining KEYS are passed directly t
381       (and       (and
382        (cvs-match "cvs[.ex]* \\[[a-z]+ aborted\\]:.*$")        (cvs-match "cvs[.ex]* \\[[a-z]+ aborted\\]:.*$")
383        (cvs-parsed-fileinfo 'MESSAGE ""))        (cvs-parsed-fileinfo 'MESSAGE ""))
384        
385       ;; sadly you can't do much with these since the path is in the repository       ;; sadly you can't do much with these since the path is in the repository
386       (cvs-match "Directory .* added to the repository$")       (cvs-match "Directory .* added to the repository$")
387       )))       )))
# Line 442  The remaining KEYS are passed directly t Line 449  The remaining KEYS are passed directly t
449        (cvs-match "Locally Removed$"     (type 'REMOVED))        (cvs-match "Locally Removed$"     (type 'REMOVED))
450        (cvs-match "Locally Modified$"    (type 'MODIFIED))        (cvs-match "Locally Modified$"    (type 'MODIFIED))
451        (cvs-match "Needs Merge$"         (type 'NEED-MERGE))        (cvs-match "Needs Merge$"         (type 'NEED-MERGE))
452          (cvs-match "Entry Invalid"        (type '(NEED-MERGE . REMOVED)))
453        (cvs-match "Unknown$"             (type 'UNKNOWN)))        (cvs-match "Unknown$"             (type 'UNKNOWN)))
454       (cvs-match "$")       (cvs-match "$")
455       (cvs-or       (cvs-or
# Line 495  The remaining KEYS are passed directly t Line 503  The remaining KEYS are passed directly t
503          ;; a `current-dir' set to something different from ""          ;; a `current-dir' set to something different from ""
504          (cvs-parsed-fileinfo (cons 'UP-TO-DATE subtype) path 'trust          (cvs-parsed-fileinfo (cons 'UP-TO-DATE subtype) path 'trust
505                               :base-rev base-rev)))                               :base-rev base-rev)))
506        
507       ;; useless message added before the actual addition: ignored       ;; useless message added before the actual addition: ignored
508       (cvs-match "RCS file: .*\ndone$"))))       (cvs-match "RCS file: .*\ndone$"))))
509    

Legend:
Removed from v.1.11  
changed lines
  Added in v.1.11.2.1

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26