Discussion:
retrieving log messages by revision
Harry Putnam
2011-10-17 14:10:22 UTC
Permalink
I'm sure its a basic operation, to retrieve log messages for a
specific revision of something, but I'm not catching on after banging
around in the manual a bit it appears that this should do what I'm
after.

cvs log -r7 some/file

But when I run that command the output does not contain the log
message.

,----
| cvs log -r7 reader/home/reader/lisp/site-start.el
|
| RCS file: /usr/local/cvsroot/base/reader/home/reader/lisp/site-start.el,v
| Working file: reader/home/reader/lisp/site-start.el
| head: 1.7
| branch:
| locks: strict
| access list:
| symbolic names:
| start-100227_222841: 1.1.1.1
| hp-100227_222841: 1.1.1
| keyword substitution: kv
| total revisions: 8; selected revisions: 0
| description:
`----

So I must be missing something basic.

A similar command but much more inclusive:
cvs log reader/home/reader/lisp/site-start.el

Does show the log message for that revision.

,----
| cvs log reader/home/reader/lisp/site-start.el |
| grep -B1 -A4 'revision 1.7'
| (Just showing the desired output)
| ----------------------------
| revision 1.7
| date: 2011-10-17 08:23:02 -0500; author: root; state: Exp; lines: +43 -37; commitid: 6AUYI0mEJAtRNHDv;
| Changed all skeletons and etc, that ouput
| formatted dates to the format yymmdd_HH:MM:SS
| ----------------------------
`----

How can I use `cvs log' to retrieve a specific revisions commit
message if any?
Mike Pumford
2011-10-17 15:04:59 UTC
Permalink
Post by Harry Putnam
I'm sure its a basic operation, to retrieve log messages for a
specific revision of something, but I'm not catching on after banging
around in the manual a bit it appears that this should do what I'm
after.
cvs log -r7 some/file
Easy. You haven't given CVS a valid revision number.

cvs log -r1.7 some/file will do what you want.

Mike
Harry Putnam
2011-10-17 18:13:31 UTC
Permalink
Post by Mike Pumford
Easy. You haven't given CVS a valid revision number.
cvs log -r1.7 some/file will do what you want.
Yikes... I could have sworn I saw something in my manual tour that
said something about `log' needing different version syntax.

Thanks.. it was the obvious choice after all.
Shane Turner
2011-10-17 14:43:38 UTC
Permalink
Post by Harry Putnam
I'm sure its a basic operation, to retrieve log messages for a
specific revision of something, but I'm not catching on after banging
around in the manual a bit it appears that this should do what I'm
after.
cvs log -r7 some/file
But when I run that command the output does not contain the log
message.
,----
| cvs log -r7 reader/home/reader/lisp/site-start.el
|
| RCS file: /usr/local/cvsroot/base/reader/home/reader/lisp/site-start.el,v
| Working file: reader/home/reader/lisp/site-start.el
| head: 1.7
| locks: strict
| start-100227_222841: 1.1.1.1
| hp-100227_222841: 1.1.1
| keyword substitution: kv
| total revisions: 8; selected revisions: 0
`----
So I must be missing something basic.
cvs log reader/home/reader/lisp/site-start.el
Does show the log message for that revision.
,----
| cvs log reader/home/reader/lisp/site-start.el |
| grep -B1 -A4 'revision 1.7'
| (Just showing the desired output)
| ----------------------------
| revision 1.7
| date: 2011-10-17 08:23:02 -0500; author: root; state: Exp; lines: +43 -37; commitid: 6AUYI0mEJAtRNHDv;
| Changed all skeletons and etc, that ouput
| formatted dates to the format yymmdd_HH:MM:SS
| ----------------------------
`----
How can I use `cvs log' to retrieve a specific revisions commit
message if any?
You didn't put the correct revison.

The command should have been:

cvs log -r*1.7* some/file

Loading...