chiark / gitweb /
c8ddb2424b38e6100cf477b77b52b1cf456d0c5d
[chiark-utils.git] / cprogs / summer.1
1 .TH SUMMER "1" "December 2006" "Debian" "Chiark-utils-bin"
2 .SH NAME
3 summer \- print checksum and system metainformation for files
4 .SH SYNOPSIS
5 .B summer -ACDbfhqt
6 .RI [\| startpoint ...]
7 .br
8 .SH DESCRIPTION
9 .B summer
10 prints the MD5 checksum of the contents, and the system
11 metainformation (ownership, permissions, timestamps, etc.), for a
12 file, or recursively for a whole directory tree.
13
14 Each command line argument should be a file or directory to be processed;
15 if it is a directory then it will be processed and then its contents will
16 also be processed, recursively. If no
17 .IR startpoint s
18 are specified on the command line then
19 .B summer
20 will read a list of newline-separated startpoints from standard input.
21
22 Since
23 .B summer
24 correctly handles devices, FIFOs and other non-regular files it is useful
25 for generating and comparing summaries of arbitrary directory trees where
26 md5sum alone would not be.
27 .SH OUTPUT FORMAT
28 .B summer
29 prints one line of information for each filesystem object it processes.
30 Each line has the following columns:
31 .TS
32 tab (@);
33 l l.
34 @MD5sum or file type information
35 @Size of file in bytes
36 @File access rights (in octal)
37 @User ID of owner
38 @Group ID of owner
39 @atime (time of last access)
40 @mtime (time of last modification)
41 @ctime (time of last status change)
42 @Filename
43 .TE
44
45 For regular files, the first column is the MD5sum. For directories, pipes,
46 symlinks and sockets it is the literal string `dir', `pipe', `symlink' or `socket'
47 as appropriate. For devices it begins with `c' for character or `b' for block
48 devices, followed by the device number as a single 32 bit hex number and as
49 four separate 8 bit hex numbers.
50
51 Note that certain characters in the filename (including spaces and `\\' characters)
52 are escaped using
53 .B \\\x\c
54 .I NN
55 syntax, where
56 .I NN
57 are two hex digits. This makes the output unambiguous. Filenames will be relative
58 if the relevant
59 .I startpoint
60 was relative, and absolute if it was absolute.
61 For symlinks the filename
62 column includes an indication of the target of the link.
63 .SH OPTIONS
64 .TP
65 .B \-A
66 Do not print the atime (time of last access). The `atime' column will be omitted.
67 .TP
68 .B \-C
69 Do not print the ctime (time of last status change). The `ctime' column will be omitted.
70 .TP
71 .B \-D
72 Do not print directory sizes. The `size' column for directories will read `dir'.
73 .TP
74 .B \-b
75 Do not print mtime (time of last modification) for symbolic links. The `mtime' field
76 for symbolic links will read `link'.
77 .TP
78 .B \-f
79 Include information about errors encountered (for example, unreadable files)
80 in the output, and continue processing. The default is to print error information
81 to standard error and stop immediately an error is encountered.
82 .TP
83 .B \-h
84 Print a brief usage message (and do nothing else).
85 .TP
86 .B \-q
87 Suppress the progress information which
88 .B summer
89 normally prints to standard error.
90 .TP
91 .B \-t
92 Set the field separator between the information and the filename to a
93 tab character (default is space).
94 .SH BUGS
95 .B summer
96 requires switches to be specified in a single argument; that is,
97 .B -ACf
98 is accepted but
99 .B -A -C -f
100 is not.
101 .SH AUTHOR
102 This Manual page was written by Peter Maydell <pmaydell@chiark.greenend.org.uk> but
103 may be used by anyone.
104 .SH COPYRIGHT
105 Copyright (C) 2003-2006 Ian Jackson <ian@chiark.greenend.org.uk>
106 .br
107 This is free software; see the source for copying conditions.  There is NO
108 warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.