Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/17/84; site bcsaic.UUCP Path: utzoo!watmath!clyde!burl!ulysses!bellcore!decvax!tektronix!uw-beaver!ssc-vax!bcsaic!michaelm From: michaelm@bcsaic.UUCP (michael maxwell) Newsgroups: net.unix Subject: SCCS unedit Message-ID: <439@bcsaic.UUCP> Date: Thu, 23-Jan-86 16:36:14 EST Article-I.D.: bcsaic.439 Posted: Thu Jan 23 16:36:14 1986 Date-Received: Mon, 27-Jan-86 03:10:57 EST Organization: Boeing Computer Services AI Center, Seattle Lines: 38 Is there a quick way to get SCCS to unedit all files which haven't been modified? My problem is this: I do an SCCS edit of the SCCS directory, which has on the order of 20 files. I do some testing of the system defined by these files, in the process modifying *some* of them. When I get done, I want SCCS to delta the modified ones, but just unedit the others. What I do now is to run sccs diffs on all 20 files. If the file has been changed, I inform the user (me) of the changes and delta it, letting the user supply the comment; otherwise I just unedit the file. The trouble is that some of these files are quite long, and it takes a long time to run sccs diffs. It occurred to me that I could examine the time of last modification of the p-file and the "gotten" file, and only run sccs diffs if the gotten file has a later date of modification. It then occurred to me that this is what "make" is supposed to do, and maybe I could get "make" to do all this for me. Now if I just had one or two files, I suppose the Makefile could have entries like this ("p.foo" is in the directory SCCS, and "foo" is in the next higher directory; the Makefile is assumed to be in the SCCS dir): p.foo: ../foo -if `sccs diffs ../foo` ; \ sccs unedit ../foo ; \ else ; \ sccs delta ../foo ; \ fi The problem is, I have 20 or so files, and add a new file from time to time; so I would have to add a new procedure in my Makefile each time I add a new file. This looks like what make's implicit rules for suffixes were made for, except that this time it's a prefix (p.), not a suffix, and there are no implicit rules for prefixes. Am I missing something? Or should I just bite the bullet and use "find -name -newer" with "for[each]" in a [c]shell script to create my own version of make? -- Mike Maxwell Boeing Artificial Intelligence Center ...uw-beaver!uw-june!bcsaic!michaelm