[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: patch for documentation about version control
From: |
Thien-Thi Nguyen |
Subject: |
Re: patch for documentation about version control |
Date: |
10 Nov 2004 04:00:36 -0500 |
Stefan Monnier <address@hidden> writes:
I'd also suggest we don't recommend RCS any more.
although RCS is old (and somewhat quirky), it is still
useful. i'm about to check in the following (changing
the names to have vc-rcs- prefix), which should extend
the lifetime of RCS ,v files if not the RCS executable
programs installed in ${bindir}, for a while yet.
i suppose support for ,v file munging does not conflict
directly w/ not recommending RCS any more, but it still
seems to me a slightly inconsistent message.
thi
_____________________________________________
;;; comma-v.el
;;;
;;; Rel:standalone-comma-v-el-2-0-0
;;;
;;; Copyright (C) 2004 Thien-Thi Nguyen
;;; This file is part of ttn's personal elisp library, released under GNU
;;; GPL with ABSOLUTELY NO WARRANTY. See the file COPYING for details.
;;;
;;; Description: Read and write RCS-style masterfiles directly.
;;; Commentary:
;; Emacs is forever, but who knows whether or not ci(1) and co(1) will be
;; around in 20 years? In any case, the true test for a data format is
;; how many programs can (easily) munge it. Long live the ,v files!
;;
;; This library provides, at heart, two reciprocal functions:
;; (comma-v-parse &optional buffer) => TREE
;; (comma-v-unparse TREE &optional buffer)
;;
;; These have been tested only on simple ASCII files w/ "linear" revisions
;; (no branches, locks, access lists or other things). There is some
;; quirkiness w/ RCS whitespace that probably will result in subtle errors.
;; Ahh, code-enhancement opportunities...
;;
;; Anyway, for the morbidly curious, here is the simple testing command:
;;
;; (defun comma-v-roundtrip (comma-v-file)
;; (interactive "fRCS masterfile: ")
;; (let* ((buf (find-file comma-v-file))
;; (tree (comma-v-parse buf)))
;; (switch-to-buffer "*comma-v-roundtrip*")
;; (erase-buffer)
;; (comma-v-unparse tree)
;; (goto-char (point-min))
;; (split-window-vertically)
;; (switch-to-buffer-other-window buf)
;; (goto-char (point-min))))
;;
;; You can then try `M-x compare-windows' and `C-u M-x compare-windows'.
;; Then for more fun, try it on a CVS-created ,v file. This is known to
;; reveal miscompares for old ,v files where the year was stored as a two-
;; digit number (for example, 98 instead of 1998). Obviously, overwriting
;; with a four-digit year is one way to prevent subsequent miscompares.
;;
;; Also provided are the functions:
;; (comma-v-annotate-command file buffer &optional revision)
;; (comma-v-annotate-current-time)
;; (comma-v-annotate-time)
;; (comma-v-annotate-extract-revision-at-line)
;; (setup-anticipatory-vc-rcs-annotation)
;;
;; The last is a command that makes `C-x v g' work for RCS files
;; by hooking the other functions into the Emacs VC framework.
;; After some refinement they should be added to Emacs directly
;; along w/ -parse and -unparse, and comma-v.el declared obsolete.
;;; Code:
[snipped (to be added to vc-rcs.el in the next couple days) --ttn]
- patch for documentation about version control, Alex Ott, 2004/11/09
- Re: patch for documentation about version control, Andre Spiegel, 2004/11/09
- Re: patch for documentation about version control, Karl Fogel, 2004/11/09
- Re: patch for documentation about version control, Stefan Monnier, 2004/11/09
- Re: patch for documentation about version control, Stefan Monnier, 2004/11/09
- Re: patch for documentation about version control, David Kastrup, 2004/11/09
- Re: patch for documentation about version control,
Thien-Thi Nguyen <=
- Re: patch for documentation about version control, Andre Spiegel, 2004/11/10
- Re: patch for documentation about version control, Thien-Thi Nguyen, 2004/11/10
- Re: patch for documentation about version control, Andre Spiegel, 2004/11/11
- Re: patch for documentation about version control, Stefan, 2004/11/11
- Re: patch for documentation about version control, Andre Spiegel, 2004/11/11
- Re: patch for documentation about version control, Thien-Thi Nguyen, 2004/11/11
- Re: patch for documentation about version control, Thien-Thi Nguyen, 2004/11/11
- Re: patch for documentation about version control, Thien-Thi Nguyen, 2004/11/11
- Re: patch for documentation about version control, Andre Spiegel, 2004/11/11
- Re: patch for documentation about version control, Thien-Thi Nguyen, 2004/11/12