Skip to content

Commit a3c69b3

Browse files
committed
Add documentation about writing records
1 parent 6a5cbe8 commit a3c69b3

1 file changed

Lines changed: 21 additions & 1 deletion

File tree

docs/source/tools/rdump.rst

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,27 @@ For example, we can output just the hostname, name and image path of a Windows s
120120
Writing records
121121
---------------
122122

123-
Something about writing records, e.g. auto detection of filename for compression.
123+
``rdump`` can write records to a file, which can be used as input for ``rdump`` at a later stage. To write
124+
records to a file, the ``-w`` or ``--writer`` argument can be used.
125+
126+
The output format and compression type are automatically detected based on the filename extension. For example, to
127+
write to a gzip compressed file, simply use the ``.gz`` extension in your output file.
128+
129+
.. code-block:: console
130+
131+
$ rdump services.rec -w services.rec.gz
132+
133+
This will read the records from ``services.rec`` and write them to a new gzip compressed file named ``services.rec.gz``.
134+
Other supported compression formats are ``.bz2``, ``.zst`` (zstandard), and ``.lz4``.
135+
136+
If you want to write the records to a file without any compression, just use a filename without a compression
137+
extension.
138+
139+
.. code-block:: console
140+
141+
$ rdump services.rec -w services.rec.out
142+
143+
If no ``-w`` argument is provided, ``rdump`` writes the records to standard output in its default line-based format.
124144

125145
Usage
126146
-----

0 commit comments

Comments
 (0)