Index: /trunk/athena/bin/rep/rep.1
===================================================================
--- /trunk/athena/bin/rep/rep.1	(revision 23)
+++ /trunk/athena/bin/rep/rep.1	(revision 23)
@@ -0,0 +1,23 @@
+.FM mit
+.TH REP 1 local 
+.SH NAME
+rep - repeatedly execute a command
+.SH SYNOPSIS
+rep [-n] command
+.SH DESCRIPTION
+.I Rep
+repeatedly executes a command and prints out the
+output in the same place each time.  (It uses
+cursor optimization routines to only update chars
+that have changed.)
+.PP
+The -n option specifies the number of seconds between
+repetitions.
+.SH EXAMPLES
+.B rep ps -ef
+.PP
+prints out a display of system activity.
+.PP
+.B rep -1 date
+.PP
+puts a digital clock on the screen.
Index: /trunk/athena/bin/rep/rep.c
===================================================================
--- /trunk/athena/bin/rep/rep.c	(revision 23)
+++ /trunk/athena/bin/rep/rep.c	(revision 23)
@@ -0,0 +1,100 @@
+/******************************************************************************
+ *									      *
+ * rep -- run a program repeatedly using 'curses'.			      *
+ *									      *
+ *	Usage: rep [-n] command						      *
+ *									      *
+ *	Permits the user to watch a program like 'w' or 'finger' change with  *
+ *	time.  Given an argument '-x' will cause a repetion every x seconds.  *
+ *									      *
+ * ORIGINAL								      *
+ * Ray Lubinsky University of Virginia, Dept. of Computer Science             *
+ *	     uucp: decvax!mcnc!ncsu!uvacs!rwl                                 *
+ * MODIFIED 3/85							      *
+ * Bruce Karsh, Univ. Wisconsin, Madison.  Dept. of Geophysics.               *
+ *           uucp: uwvax\!geowhiz\!karsh				      *
+ ******************************************************************************/
+
+#include <curses.h>
+#include <signal.h>
+
+#define	NextLine	fgets(buf,sizeof buf,input)
+
+FILE	*input;				/* Pipe from 'source' */
+char	source[512];			/* Source program to run repeatedly */
+char	*progname;			/* Name of this program (for errors) */
+int	interval = 1;			/* Seconds between repitions */
+int	deathflag = 0;			/* Set by interupt trap routine */
+
+main(argc,argv)
+	int	argc;
+	char	**argv;
+{
+	int	endrep();		/* Mop up routine on break */
+	FILE	*popen();
+
+	char	buf[BUFSIZ];		/* Buffer holds a line from 'source' */
+	int	i;
+
+	progname = *argv;
+        source[0]=0;
+	if (argc == 1)
+		badargs();
+	if (**(argv+1) == '-')		/* User specified interval */
+		if ((--argc == 1) || ((interval = atoi(*(++argv)+1)) == 0))
+			badargs();
+	while (--argc > 0) {		/* Argument becomes source program */
+		strcat(source,*++argv);
+		strcat(source," ");
+	}
+	signal(SIGINT,endrep);
+	if(deathflag == 1)goto die;
+	initscr();
+	if(deathflag == 1)goto die;
+	crmode();
+	if(deathflag == 1)goto die;
+	nonl();
+	if(deathflag == 1)goto die;
+	clear();
+	if(deathflag == 1)goto die;
+	for (;;) {
+		if(deathflag == 1)goto die;
+		if ((input = popen(source,"r")) == NULL) {
+			fprintf(stderr,"%s: can't run %s\n",progname,source);
+			goto die;
+		}
+		for (i = 0; (i < LINES) && (NextLine != NULL); i++) {
+			mvaddstr(i,0,buf);
+			clrtoeol();
+			if(deathflag == 1)goto die;
+		}
+		if(deathflag == 1)goto die;
+		pclose(input);
+		if(deathflag == 1)goto die;
+		clrtobot();
+		if(deathflag == 1)goto die;
+		refresh();
+		if(deathflag == 1)goto die;
+		sleep(interval);
+		if(deathflag == 1)goto die;
+	}
+die:
+signal(SIGINT,SIG_IGN);
+if (input != NULL)
+	pclose(input);
+clear();
+refresh();
+endwin();
+exit(0);
+}
+
+endrep()
+{
+deathflag=1;
+}
+
+badargs()
+{
+	fprintf(stderr,"Usage: %s [-n] command\n",progname);
+	exit(1);
+}
Index: /trunk/athena/bin/rep/Makefile
===================================================================
--- /trunk/athena/bin/rep/Makefile	(revision 20)
+++ /trunk/athena/bin/rep/Makefile	(revision 27)
@@ -3,10 +3,8 @@
 #	$Author: builder $
 #	$Locker:  $
-#	$Header: /afs/dev.mit.edu/source/repository/athena/bin/rep/Makefile,v 1.3 1985-06-17 14:34:11 builder Exp $
+#	$Header: /afs/dev.mit.edu/source/repository/athena/bin/rep/Makefile,v 1.5 1985-11-13 21:22:05 builder Exp $
 #
 DESTDIR=
-PHYSLOC=/u1
-INCDIR=/usr/include
-CFLAGS=-O -I${INCDIR}
+CFLAGS=-O 
 
 all: rep
@@ -15,5 +13,6 @@
 	cc ${CFLAGS} rep.c -lcurses -ltermlib -o rep
 install: rep
-	install -c -s rep ${DESTDIR}${PHYSLOC}/usr/athena/rep
+	install -c -s rep ${DESTDIR}/usr/athena/rep
+	install -c rep.1 ${DESTDIR}/usr/man/mann/rep.n
 
 clean:
Index: /trunk/athena/bin/sendbug/Makefile
===================================================================
--- /trunk/athena/bin/sendbug/Makefile	(revision 20)
+++ /trunk/athena/bin/sendbug/Makefile	(revision 28)
@@ -3,10 +3,9 @@
 #	$Author: builder $
 #	$Locker:  $
-#	$Header: /afs/dev.mit.edu/source/repository/athena/bin/sendbug/Makefile,v 1.2 1985-06-17 14:31:52 builder Exp $
+#	$Header: /afs/dev.mit.edu/source/repository/athena/bin/sendbug/Makefile,v 1.3 1985-11-13 21:24:48 builder Exp $
 #
 
 
 DESTDIR=
-PHYSLOC=/u1
 CONFDIR= /usr/athena
 
@@ -14,6 +13,6 @@
 
 install: 
-	install -c sendbug.sh ${DESTDIR}${PHYSLOC}${CONFDIR}/sendbug
-	install -c bug_report ${DESTDIR}${PHYSLOC}${CONFDIR}/lib/bug_report
+	install -c sendbug.sh ${DESTDIR}${CONFDIR}/sendbug
+	install -c bug_report ${DESTDIR}${CONFDIR}/lib/bug_report
 
 clean:
Index: /trunk/athena/bin/mon/vm.c
===================================================================
--- /trunk/athena/bin/mon/vm.c	(revision 2)
+++ /trunk/athena/bin/mon/vm.c	(revision 25)
@@ -1,11 +1,11 @@
 /*
  *	$Source: /afs/dev.mit.edu/source/repository/athena/bin/mon/vm.c,v $
- *	$Author: dgg $
+ *	$Author: builder $
  *	$Locker:  $
- *	$Header: /afs/dev.mit.edu/source/repository/athena/bin/mon/vm.c,v 1.1 1984-12-13 12:01:38 dgg Exp $
+ *	$Header: /afs/dev.mit.edu/source/repository/athena/bin/mon/vm.c,v 1.2 1985-11-13 00:05:10 builder Exp $
  */
 
 #ifndef lint
-static char *rcsid_vm_c = "$Header: /afs/dev.mit.edu/source/repository/athena/bin/mon/vm.c,v 1.1 1984-12-13 12:01:38 dgg Exp $";
+static char *rcsid_vm_c = "$Header: /afs/dev.mit.edu/source/repository/athena/bin/mon/vm.c,v 1.2 1985-11-13 00:05:10 builder Exp $";
 #endif	lint
 
@@ -23,5 +23,5 @@
 
 #include "mon.h"
-#include <machine/param.h>	/* defines bytes/page */
+#include <machine/machparam.h>	/* defines bytes/page */
 
 /* Temporary defines */
Index: /trunk/athena/bin/mon/Makefile
===================================================================
--- /trunk/athena/bin/mon/Makefile	(revision 3)
+++ /trunk/athena/bin/mon/Makefile	(revision 26)
@@ -1,7 +1,7 @@
 #
 # 	$Source: /afs/dev.mit.edu/source/repository/athena/bin/mon/Makefile,v $
-#	$Author: dgg $
+#	$Author: builder $
 #	$Locker:  $
-#	$Header: /afs/dev.mit.edu/source/repository/athena/bin/mon/Makefile,v 1.2 1984-12-13 12:10:16 dgg Exp $
+#	$Header: /afs/dev.mit.edu/source/repository/athena/bin/mon/Makefile,v 1.5 1985-11-13 20:50:00 builder Exp $
 #
 
@@ -22,5 +22,5 @@
 
 install:
-	install -c -s -g memory -m 2755 mon ${DESTDIR}/etc/athena/mon
+	install -c -s -g kmem -m 2755 mon ${DESTDIR}/usr/athena/mon
 
 clean:
Index: /trunk/athena/bin/tarmail/Makefile
===================================================================
--- /trunk/athena/bin/tarmail/Makefile	(revision 20)
+++ /trunk/athena/bin/tarmail/Makefile	(revision 30)
@@ -3,7 +3,6 @@
 #	$Author: builder $
 #	$Locker:  $
-#	$Header: /afs/dev.mit.edu/source/repository/athena/bin/tarmail/Makefile,v 1.4 1985-06-17 14:33:16 builder Exp $
+#	$Header: /afs/dev.mit.edu/source/repository/athena/bin/tarmail/Makefile,v 1.6 1985-11-13 22:51:30 builder Exp $
 #
-PHYSLOC=/u1
 DESTDIR=
 INCDIR=/usr/include
@@ -13,7 +12,8 @@
 
 install:	atob btoa tarmail untarmail
-	install -c -s btoa ${DESTDIR}${PHYSLOC}/usr/athena
-	install -c -s atob ${DESTDIR}${PHYSLOC}/usr/athena
-	cp tarmail untarmail ${DESTDIR}${PHYSLOC}/usr/athena
+	install -c -s btoa ${DESTDIR}/usr/athena
+	install -c -s atob ${DESTDIR}/usr/athena
+	install -c tarmail ${DESTDIR}/usr/athena
+	install -c untarmail ${DESTDIR}/usr/athena
 
 btoa:
