DRECORD

Section: User Commands (1)
Index Return to Main Contents

BSD mandoc
 

NAME

drecord - search or retrieve text key/value records from stdin  

SYNOPSIS

[-m ] [query ]  

DESCRIPTION

The utility takes in a text-based key/value pair format on the standard input and prints any lines that form either an exact match or a fuzzy match, depending on the user's choice.

The input text must match the specified format exactly, otherwise the program returns an error status.

The options are as follows:

-m
Perform an exact match instead of the default fuzzy match.
 

EXIT STATUS

Ex -std drecord  

FORMAT

Files compatible with must be text-only, and utilize the following format:

      key:    value
      key2:   value2

Keys may contain any non-whitespace character, and values may contain any character except a new-line, which indicates a new record.

Whitespace may appear anywhere directly before or after the colon, for example:

      key    :   value
      key2   :   value2

You will notice that the format is very similar, but not identical to, the one used in ~/.Xresources  

EXAMPLES

The command:
drecord -m password < file

Will print any lines in file where the left-hand value (the key) matches ``password'' exactly.

The command:

diary -di file | drecord email

will use diary(1) to decrypt file and then search through it with this program, returning any lines where the key contains (but does not exactly match) the word ``email''  

SEE ALSO

diary(1)


 

Index

NAME
SYNOPSIS
DESCRIPTION
EXIT STATUS
FORMAT
EXAMPLES
SEE ALSO

This document was created by man2html, using the manual pages.
Time: 20:41:42 GMT, July 27, 2026