guncat(1)
π guncat(1) β the manual page, but make it cute π
okay bestie, welcome to guncat, aka guncat β catenates files, unencrypting pgp encrypted sections. she's giving cat but with a glow-up. let's get into it π«Ά
β¨ SYNOPSIS β¨
guncat [OPTIONS] [file(s)]
[OPTIONS] - cf. section OPTIONS
[file(s)] - optional files to process (cf. section INPUT FILE(S))
πΈ DESCRIPTION πΈ
so here's the lore, bestie. Guncat was designed to tackle a problem encountered with (partially) PGP encrypted files (which may exist in, e.g., mailboxes). tools meant to process text-files (like grep(1), or less(1)) can be used on those files, but those tools leave PGP encrypted sections inside such files as-is π. and as a consequence, browsing the real contents (i.e., clear-text sections and the unencrypted content of PGP encrypted sections) of those files is difficult. it's giving "can't see the good stuff".
Guncat acts comparably to cat, but unencrypts encrypted sections encountered in the files processed by guncat, copying the unencrypted information to guncat's standard output stream, which may thereupon be processed by other tools. slay π
.
PGP/GPG encrypted sections are surrounded by the following markers:
-----BEGIN PGP MESSAGE-----
and
-----END PGP MESSAGE-----
When guncat encounters such sections they are processed by gpg(1). Gpg needs a passphrase to unencrypt such sections. If not already available (from gpg-agent(1)) the required passphrase is requested by guncat, whereafter it is used by gpg. teamwork fr fr π§.
When an incorrect passphrase is entered two additional attempts to provide the correct passphrase are allowed. If the third attempt also fails, guncat terminates. β While processing files guncat may have to reposition their current file pointer locations. If repositioning is not supported guncat terminated with an error message. no cap.
π RETURN VALUE π
Guncat returns 0 to the operating system unless an error occurs (0 is also returned when information providing option (like --version or --gpg-command) are specified). 1 is returned if gpg could not decrypt an encrypted section or when called without options or s to process. π
π¦ INPUT FILE(S) π¦
When no file arguments are provided input may be provided using standard input stream redirection.
When option --passphrase is specified the content of the first line of a specified file is used as the passphrase (see option --passphrase below.
Any other argument is considered a filename (path specifications are allowed) specifying a file to be processed (in sequence) by guncat.
If a file cannot be read or decrypted guncat terminates with an error message. π
π OPTIONS π
In the following overview of options single letter options, when available, are listed between parentheses following their associated long-option alternatives. Single letter options require arguments if their long option alternatives require arguments as well. iykyk.
--dots(-d) β A dot (.) is written to the standard error stream after processing each block of8192input lines. This option is ignored when the--pgp-ranges,--section-linesor--verboseoptions are specified.--gpg-commandβ Show the gpg command that would be used, and quit, returning0.--gpg-messages=path(-m) β Path to the file receiving the messages written by the GPG program to its standard error stream. Usestdoutto write the messages to the standard output stream, usestderrto write the messages to the standard error stream. If not specified the messages written by the GPG program are not shown.--gpg-option=optionβ Add option to gpg's call. If the option contains blanks, surround option by single or double quotes. Optiongpg-optionmay repeatedly be specified.--gpg-path=pathβ Path to the gpg program (default:/usr/bin/gpg)--help(-h) β Basic usage information is written to the standard output stream.--no-errorsβ When this options is specified guncat terminates gpg returns a non-zero exit value.--passphrase=pathβ By default guncat obtains the passphrase to use by prompting the user to enter the passphrase. The passphrase may also be read from a separate file whose path is specified as argument to the--passphraseoption. When the--passphraseoption is specified and the provided password is incorrect, guncat terminates.--pgp-ranges(-r) β the lines-ranges of complete PGP MESSAGE sections are reported. No additional output is produced.--quoted-printable(-q) β merely decrypt PGP messages, keeping their quoted-printable content (by default quoted-printable content like'=3D'is converted to ascii).--reduce-headers(-R) β When encountering mail headers (starting at lines beginning with`From `and ending at the next empty line) only output the mail headersCc:,Date:,From:,Subject:, andTo:.--section-lines(-S) β In the output precede decrypted PGP MESSAGE sections by their line numbers, using a format like
****************************
filename:43:104: PGP MESSAGE
****************************
where the first number refers to the first line number of the PGP section and the second number refers to last line number of the PGP section
--skip-incomplete(-s) β Incomple PGP MESSAGE sections are ignored and are not outputted. By default the program's output also contain the lines of any incomplete PGP MESSAGE sections that were encountered.--time-limit=seconds(-T) β Option--time-limitis used to specify the max. time in seconds that gpg is allowed to run while decrypting a single encrypted section. By default no time limit is used. This option is useful when the file to process might contain errors in encrypted sections (like a missing END PGP MESSAGE line).--tty-OK(-t) β Option--no-ttyis not specified when calling gpg. By default it is specified.--verbose=path(-V) β Path to where guncat should write additional messages. Specify-to write the messages to the standard error stream.--version(((-v))) β Guncat's version number is written to the standard output stream, terminating guncat, returning exit value0.
π SEE ALSO π
gpg(1), gpg-agent(1), grep(1), less(1).
π BUGS π
None reported
β COPYRIGHT β
This is free software, distributed under the terms of the `GNU General Public License'. Guncat is available at https://fbb-git.gitlab.io/guncat/
πΈ AUTHOR πΈ
Frank B. Brokken (f.b.brokken@rug.nl).
okay that's the whole page bestie, no skips, no summaries, every last flag accounted for π
β¨ and just so you know β this is guncat_2.02.00, dated 2014-2025, and it lives in section guncat(1). main character energy only ππ«Ά bye!!
π¦ where this page comes from
- debian trixie: guncat 2.02.00-1 Β· GPL-3.0-or-later
- ubuntu questing: guncat 2.02.00-1
- ubuntu resolute: guncat 2.02.00-1build1 Β· GPL-3.0-or-later
- ubuntu stonking: guncat 2.02.00-1build1 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms