BRIK
Section: User Commands (1)
Updated: Jul 8, 1989
Index
Return to Main Contents
NAME
brik - calculate 32-bit CRC
SYNOPSIS
brik -h
brik -gcGCbafvsqWHT
file ...
DESCRIPTION
Brik
generates and verifies 32-bit CRC values (checksums). It is
designed to generate CRCs for text files that are the same on all computer
systems that use the ASCII character set, provided each text file is in the
usual text file format for each system.
Brik
will also optionally use
binary CRCs calculated using every byte in a file. Such binary CRCs are
portable across systems for binary files that are moved from system to system
without any newline conversion.
Brik
can be asked to decide by examining
each file whether to calculate a text mode or binary mode CRC for it.
Changes from version 1.0 are summarized at the end of this document.
The general usage format is:
-
brik -gcGCbafvsqWHT
[
file
] ...
The brackets mean that
file,
which is the name of a file, is optional. The
three dots indicate that more than one filename may be typed (separated by
blanks). Exactly one of the options
-c,
-C,
-g,
-G,
or
-h,
is required. The
-h
option gives a help screen.
In addition to
-h,
the
Brik
options available (as they appear on the help
screen) are:
- -g
-
look for
Checksum:
header, generate CRC for rest of file
- -c
-
get CRC from header, verify CRC of rest of file
- -G
-
generate CRC for entire file (add
-b
for binary files)
- -C
-
verify all file CRCs from output of
-G
(-f
is not needed)
- -b
-
use binary mode -- read file byte by byte, not line by line
- -a
-
automatically decide whether each file is text or binary
- -f
-
read filenames (wildcards ok) from specified files
- -v
-
be verbose, report all results (else only errors are reported)
- -s
-
be silent, say nothing, just return status code
- -q
-
be quiet, don't print header for
-G
- -W
-
after generating CRC with
-g,
write it to original header
- -H
-
after generating CRC with
-g,
print header to stdout
- -T
-
include trailing empty lines, normally ignored (text mode only)
VERIFYING CRC HEADERS
The primary intended use of
Brik
is to verify
Checksum:
headers in Usenet
postings and in C and Pascal source files. A
Checksum:
header looks like
this: