Re: Suggested new feature for ci
Thien-Thi Nguyen <[email protected]> Tue, 09 Nov 2010 05:05:08 +0100
| Newsgroups | gmane.comp.version-control.rcs.bugs |
|---|---|
| Message-ID | <[email protected]> |
() Keith Thompson <[email protected]> () Mon, 8 Nov 2010 12:36:47 -0800 The "-m" option of the "ci" command makes it difficult to specify an empty log message. A workaround I often use is ci -l filename < /dev/null Note that "cvs commit" has a similar "-m" option, but the log message is always given as a separate argument, not bundled with the option. Just copying that behavior for ci would probably break too many existing scripts. Yes, that way is problematic. One possible solution, though it's a bit ugly, might be to define behavior for an argument consisting of just "-m" (which is currently an error): -mmsg Uses "msg" as the message. -m Uses the following argument as the message. So ci -m '' foo would check in "foo" with an empty log message, and a non-empty message could be given either as: ci -mmessage foo or ci -m message foo Interesting idea. It doesn't seem ugly by itself, at first glance, but it being different from all the other options is indeed a disadvantage. Another idea is to check an env var (say, RCS_DEFAULT_LOG_MESSAGE) to use prior to throwing "missing message for -m option" error. What do you think of that?