Fix a piece of embarrassingly untested pointer-twiddling.
[sgt/agedu] / agedu.but
index de47dd2..3fc1a23 100644 (file)
--- a/agedu.but
+++ b/agedu.but
@@ -6,8 +6,8 @@
 
 \U NAME
 
-\cw{agedu} - correlate disk usage with last-access times to identify
-large and disused data
+\cw{agedu} \dash correlate disk usage with last-access times to
+identify large and disused data
 
 \U SYNOPSIS
 
@@ -65,10 +65,13 @@ mode:
 which will print (among other messages) a URL on its standard output
 along the lines of
 
-\c URL: http://127.164.152.163:48638/
+\c URL: http://127.0.0.1:48638/
 
 (That URL will always begin with \cq{127.}, meaning that it's in the
-\cw{localhost} address space.)
+\cw{localhost} address space. So only processes running on the same
+computer can even try to connect to that web server, and also there
+is access control to prevent other users from seeing it \dash see
+below for more detail.)
 
 Now paste that URL into your web browser, and you will be shown a
 graphical representation of the disk usage in \cw{/home/fred} and
@@ -241,9 +244,11 @@ whereas \cw{-S} will not.
 
 \lcont{
 
-(Actually, the output will not be exactly identical, due to a
-difference in treatment of last-access times on directories. See the
-documentation of the \cw{--dir-atime} option in the next section.
+(The output will not be exactly \e{identical}, due to a
+difference in treatment of last-access times on directories.
+However, it should be effectively equivalent for most purposes. See
+the documentation of the \cw{--dir-atime} option in the next section
+for further detail.)
 
 }
 
@@ -438,8 +443,32 @@ complexity.)
 
 }
 
+\dt \cw{--mtime}
+
+\dd This option causes \cw{agedu} to index files by their last
+modification time instead of their last access time. You might want
+to use this if your last access times were completely useless for
+some reason: for example, if you had recently searched every file on
+your system, the system would have lost all the information about
+what files you hadn't recently accessed before then. Using this
+option is liable to be less effective at finding genuinely wasted
+space than the normal mode (that is, it will be more likely to flag
+things as disused when they're not, so you will have more candidates
+to go through by hand looking for data you don't need), but may be
+better than nothing if your last-access times are unhelpful.
+
+The following option affects all the modes that generate reports:
+the web server mode \cw{-w}, the stand-alone HTML generation mode
+\cw{-H} and the text report mode \cw{-t}.
+
+\dt \cw{--files}
+
+\dd This option causes \cw{agedu}'s reports to list the individual
+files in each directory, instead of just giving a combined report
+for everything that's not in a subdirectory.
+
 The following options affect the web server mode \cw{-w}, and in one
-case also the stand-along HTML generation mode \cw{-H}:
+case also the stand-alone HTML generation mode \cw{-H}:
 
 \dt \cw{-r} \e{age range} or \cw{--age-range} \e{age range}
 
@@ -476,8 +505,8 @@ three months ago or later.
 \cw{agedu} should listen when running its web server. If you want
 \cw{agedu} to listen for connections coming in from any source, you
 should probably specify the special IP address \cw{0.0.0.0}. If the
-port number is omitted, it will be assumed to be 80 (for which
-\cw{agedu} will probably need to be running as a privileged user).
+port number is omitted, an arbitrary unused port will be chosen for
+you and displayed.
 
 \lcont{
 
@@ -553,13 +582,13 @@ efficiently perform the queries it needs; this data structure
 requires \cw{O(N log N)} storage. This is larger than you might
 expect; a scan of my own home directory, containing half a million
 files and directories and about 20Gb of data, produced an index file
-nearly a third of a Gb in size. Furthermore, since the data file
-must be memory-mapped during most processing, it can never grow
-larger than available address space, which means that any use of
-\cw{agedu} on a seriously large file system is probably going to
-have to be done on a 64-bit computer.
-
-Also, \cw{agedu} has not yet been \e{tested} on a 64-bit computer.
+over 60Mb in size. Furthermore, since the data file must be
+memory-mapped during most processing, it can never grow larger than
+available address space, so a \e{really} big filesystem may need to
+be indexed on a 64-bit computer. (This is one reason for the
+existence of the \cw{-D} and \cw{-L} options: you can do the
+scanning on the machine with access to the filesystem, and the
+indexing on a machine big enough to handle it.)
 
 The data structure also does not usefully permit access control
 within the data file, so it would be difficult \dash even given the