info-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

cvse (CVS Edit) program


From: Øyvind A . Holm
Subject: cvse (CVS Edit) program
Date: Sat, 24 May 2003 11:16:14 +0200 (CEST)

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi folks,

I've written a Perl script I hope will be useful for you CVS guys. To
quote from the man page:

  NAME
      cvse -- CVSEdit -- edit CVS log messages

  SYNOPSIS
      cvse [logfile [...]]

  DESCRIPTION
      cvse is a Perl script which changes CVS log messages for one or
      many files based on the output from a regular "cvs log" command.
      This makes it easy to edit lots of messages and then run the
      script once which changes all the modified messages.

      An easy way to do this can be:

      1. Go to the directory where your source files are, or check out a
         new revision into an empty directory.
      2. Run "cvs log >logfile.txt"
      3. Edit logfile.txt (or whatever you call it) with your favourite
         text editor.
      4. Run "cvse logfile.txt"

      All the messages you modified will now be changed by CVS using the
      "cvs admin" command. Unchanged messages will not be updated.

      Another, faster way is to just read the output into your editor,
      edit it and filter the file through cvse. An example on how to do
      this in the vi(1) editor:

        :r !cvs log myfile.c
        [make changes]
        :%!cvse

      Done!

The reason I created this script in the first place, was the need to
convert all the log messages in my repository from ISO-8859-1 to the
UTF-8 charset, and there were _way_ too many files to do it manually. I
was first thinking of creating a "run-once-and-never-again" script, but
then I thought having a program like this for editing messages would be
a nice thing to have around. The whole convertion was done in ten
minutes on a 233Mhz laptop for 1576 files containing 6585 revisions. No
errors occured.

The script is tested with Perl 5.6.1 and 5.8. CVS 1.11.1.p1 and the
newest CVS version from the official CVS repository is also tested.

I hope this script can be of some use, and suggestions and error reports
are very welcome.

The script (with documentation) can be downloaded from

  http://www.sunbase.org/src/cvse/

About the name of the program: Hope it doesn't clash with any other
program, but I first tried an "apt-cache search cvse" and searched for
"man cvse" on Google and got no hits, so I guess I'm safe. :-)

Regards,
Øyvind
=====================
cat /dev/urandom >SCO

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iEYEARECAAYFAj7PNCwACgkQck6dU2KQIuso9wCgjmHzBsH3HxDgTzkhsw9eYK96
6TcAoJV0XFytnupRRTnNH0rKgjgc6zU/
=zUQm
-----END PGP SIGNATURE-----





reply via email to

[Prev in Thread] Current Thread [Next in Thread]