Date: Wed, 18 Feb 1998 09:04:46 -0500 From: Max Euston <meuston@jmrodgers.com> To: "'ac199@hwcn.org'" <ac199@hwcn.org> Cc: "'FreeBSD Hackers'" <freebsd-hackers@FreeBSD.ORG>, "'Mike Smith'" <mike@smith.net.au> Subject: RE: Modifications to more(1) Message-ID: <01BD3C4C.4336FC60.meuston@jmrodgers.com>
next in thread | raw e-mail | index | archive | help
On Wednesday, February 18, 1998 5:09 AM, Tim Vanderhoek [SMTP:ac199@hwcn.org] wrote: > On Tue, 17 Feb 1998, Max Euston wrote: > [...discussion of investigating previous revisions of a small set of files...] > > This is easiest to do using the CVSweb interface at > http://www.FreeBSD.ORG/cgi/cvsweb.cgi/. It's reasonably > intuitive. :) > > If you have access to a copy of the (large) CVS repository, you > can extract any desired version with cvs co -D date, -r tag (eg. > RELENG_2_2_5_RELEASE), or a single file with -r version.number. > Instead of having the whole cvs repo locally, you could probably > get away with just the CVSROOT and src/usr.bin/more from > ftp://ftp.FreeBSD.ORG/pub/FreeBSD/FreeBSD-cvs/. (Since you can > probably discover how long -# hasn't worked from just one or two > files, it's probably easiest to use CVSweb). > > eg. > > $ cvs co --help > $ cvs co -r 1.3 src/usr.bin/more/more.c (or whatever) > I will use the web interface this time (I thought the repository might be _large_ - I will look at installing and keeping it updated on a new, larger machine I am setting up for FreeBSD). [...discussion of (broken) '-#' option in more(1)...] > FWIW, it's probably safe to remove the option without even > checking how long it hasn't worked, although just looking at the > cvs history, I suspect it hasn't worked for a long time. What > was it actually supposed to do, again? (since I've already got a > couple old versions checked-out I can just try it now :). > >From the code: it is to set the screen height of the terminal (override TERM=); you can quickly see this in 'more/option.c'. >From an (old) AT&T SVR4 system: '-#' does not exist, but '+#' is used to start paging at line '#' and '+/<pat>' is to start paging at the RE <pat>. (Was it's intended use? - I don't know, but probably so). [...install source or binary for CVSup...] > It takes some serious machinery to build CVSup (mostly due to its > modula-3 requirements, I think). A lot of people use the package, > I believe. Note that CVSup and CVS are two different (but very > closely related) things. > Thanks, Mike said this too (I guess access to all that source code just made me Ga-Ga :-) I will install the binary. > > > If I make changes to existing source code that does NOT follow current > > FreeBSD style (indents, header files, etc...), is it proper to maintain the > > style of the existing code or should I use the newer format? (e.g. should I > > "#include <string.h>" or "extern char *strcat()")? > > Yes. Follow existing style. Or restyle according to style(9). > Don't try to combine the two. :) In general. Style is style, > and whoever reviews/commits it may have their own opinion, but > the easiest thing to do is follow the existing style unless it is > significantly dysfunctional. > > (Using "extern char *strcat()" is probably dysfunctional, and I > would "#include <string.h>"...) > I had looked at style(9), but wasn't sure that it should _always_ be followed. My intention (and habit) was to maintain the original code's style unless I made massive changes or had a major problem with it. BTW: style(9) is _very_ close to my own personal preference (that made me very happy 8-). The only minor difference is that I DO include {} around 1-line blocks in an 'if' statement (since many of us have added an indented line to existing code and not always seen that we need to bracket it) - I will get used to that :( > > > Should I change the 'sccsid[]' date and/or version number? > > No. > As I thought - thanks. > You can even comment-out the sccsid[] and add > > static const char rcsid[] = > "$Id$"; > > after it. See for example > http://www.FreeBSD.ORG/cgi/cvsweb.cgi/src/usr.bin/su/su.c.diff?r1=1.11&r 2=1.12/. > Or you can just leave that part untouched. > I will leave it alone (I knew this was from the (old) SCCS system - I used to use it a looong time ago). > > -- > tIM...HOEk > OPTIMIZATION: the process of using many one-letter variables names > hoping that the resultant code will run faster. > Thanks to you and Mike for the feedback! ----- Max Euston <meuston@jmrodgers.com> Sysadm, Programmer, etc... To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?01BD3C4C.4336FC60.meuston>