17.6 Invoking recfix
recfix checks and fixes rec files. Synopsis:
recfix [option]... [operation] [op_option]... [file]
If no file is specified then the command acts like a filter,
getting the data from standard input and writing the result to
standard output.
In addition to the common options described earlier (see Common Options) the program accepts the following global options.
- ‘--no-external’
- Don't use external record descriptors.
The effect of running recfix depends on the operation it
performs. The operation mode is selected by using one of the
following options.
- ‘--check’
- Check the integrity of the database contained in the file, printing
diagnostics messages in case something is not right. This is the
default operation.
- ‘--sort’
- Perform a physical sort of all the records contained in the file (or
standard input) after checking for its integrity. The sorting
criteria are provided by the
%sort
special field, if any. If
there is an integrity failure the sorting is not performed.
This is a destructive operation.
- ‘--decrypt’
- ‘--encrypt’
- Decrypt (encrypt) all the (non-)encrypted fields in the database which are marked
as confidential. This operation requires a password. If no password
is specified with -s and the program is run in a terminal, a
prompt is given to get the password from the user.
If encryption is performed on a file having encrypted fields, the
operation will fail unless ‘--force’ is used.
These are destructive operations.
- ‘--auto’
- Insert auto-generated fields as appropriate in the records which are
missing them.
This is a destructive operation.
As described above, some operations make use of these additional options:
- ‘-s secret’
- ‘--password=secret’
- Password used to encrypt or decrypt fields.
- ‘--force’
- Force potentially dangerous operations.