UNCOMPRESS(1P)

πŸ’– UNCOMPRESS(1P) πŸ’–

okay bestie, so this one's from the POSIX Programmer's Manual (the UNCOMPRESS(1P) page, one-P for "portable, periodt") and it's literally the un-glow-up button for your compress-ed files. let's get into it ✨


🌸 PROLOG 🌸

so like, real talk first: this manual page is part of the POSIX Programmer's Manual. the Linux implementation of this interface may differ (so if you're on Linux, go check the corresponding Linux manual page for the actual tea β˜•), or the interface might not even be implemented on Linux at all. not me warning you upfront, but yes πŸ’…


πŸ‘‘ NAME πŸ‘‘

uncompress β€” expand compressed data πŸ¦‹


✨ SYNOPSIS ✨

uncompress [-cfv] [file...]

πŸ’œ DESCRIPTION πŸ’œ

The uncompress utility shall restore files to their original state after they have been compressed using the compress utility. iconic behavior, honestly.

If no files are specified, the standard input shall be uncompressed to the standard output. and if the invoking process has appropriate privileges, the ownership, modes, access time, and modification time of the original file shall be preserved β€” like, it puts everything back exactly how it found it. main character energy fr fr.

This utility shall support the uncompressing of any files produced by the compress utility on the same implementation. For files produced by compress on other systems, uncompress supports 9 to 14-bit compression (see compress, -b); it is implementation-defined whether values of -b greater than 14 are supported. so like, 9–14 bits? slay. 15+? that's a "depends on your implementation" situation, no cap.


πŸ’… OPTIONS πŸ’…

The uncompress utility shall conform to the Base Definitions volume of POSIX.1‐2017, Section 12.2, Utility Syntax Guidelines, except that Guideline 1 does apply since the utility name has ten letters. (ten letters! she's long, she's valid, she counts. periodt.)

The following options shall be supported:

  • -c β€” write to standard output; no files are changed. just peek, don't touch 🫢
  • -f β€” do not prompt for overwriting files. Except when run in the background, if -f is not given the user shall be prompted as to whether an existing file should be overwritten. If the standard input is not a terminal and -f is not given, uncompress shall write a diagnostic message to standard error and exit with a status greater than zero. so like, no -f means she's gonna ask, and if there's nobody to ask (non-terminal stdin, no -f) she just yells into stderr and dips 😭
  • -v β€” write messages to standard error concerning the expansion of each file. verbose queen πŸ‘‘

πŸŽ€ OPERANDS πŸŽ€

The following operand shall be supported:

  • file β€” a pathname of a file. If file already has the .Z suffix specified, it shall be used as the input file and the output file shall be named file with the .Z suffix removed. Otherwise, file shall be used as the name of the output file and file with the .Z suffix appended shall be used as the input file.

so basically: .Z on the end? that's your input, and she strips it off for the output. no .Z? then that's your output name, and she goes looking for file.Z as the input. it's giving "she knows where you live" πŸ¦‹


🌈 STDIN 🌈

The standard input shall be used only if no file operands are specified, or if a file operand is '-'.


πŸ“ INPUT FILES πŸ“

Input files shall be in the format produced by the compress utility. (so like, don't just hand her any random bytes, bestie πŸ™ˆ)


πŸ’– ENVIRONMENT VARIABLES πŸ’–

The following environment variables shall affect the execution of uncompress:

  • LANG β€” provide a default value for the internationalization variables that are unset or null. (See the Base Definitions volume of POSIX.1‐2017, Section 8.2, Internationalization Variables for the precedence of internationalization variables used to determine the values of locale categories.)
  • LC_ALL β€” if set to a non-empty string value, override the values of all the other internationalization variables. she overrides everything, no apologies πŸ’…
  • LC_CTYPE β€” determine the locale for the interpretation of sequences of bytes of text data as characters (for example, single-byte as opposed to multi-byte characters in arguments).
  • LC_MESSAGES β€” determine the locale that should be used to affect the format and contents of diagnostic messages written to standard error.
  • NLSPATH β€” determine the location of message catalogs for the processing of LC_MESSAGES.

🧚 ASYNCHRONOUS EVENTS 🧚

Default. (she's unbothered, she's at peace 🌸)


⭐ STDOUT ⭐

When there are no file operands or the -c option is specified, the uncompressed output is written to standard output.


πŸ”₯ STDERR πŸ”₯

Prompts shall be written to the standard error output under the conditions specified in the DESCRIPTION and OPTIONS sections. The prompts shall contain the file pathname, but their format is otherwise unspecified. Otherwise, the standard error output shall be used only for diagnostic messages.

(so like, if she's asking "hey, overwrite this?" she says which file, but the exact wording is unspecified. she keeps it mysterious πŸ’€)


🌸 OUTPUT FILES 🌸

Output files are the same as the respective input files to compress. full circle moment.


🫢 EXTENDED DESCRIPTION 🫢

None. (nothing extra, she said what she said.)


πŸ’œ EXIT STATUS πŸ’œ

The following exit values shall be returned:

  • 0 β€” successful completion. ate. ✨
  • >0 β€” an error occurred.

😭 CONSEQUENCES OF ERRORS 😭

The input file remains unmodified. (so like, if it goes wrong, at least she didn't ruin your original. she would never πŸ₯Ί)

The following sections are informative.


πŸ’… APPLICATION USAGE πŸ’…

The limit of 14 on the compress -b bits argument is to achieve portability to all systems (within the restrictions imposed by the lack of an explicit published file format). Some implementations based on 16-bit architectures cannot support 15 or 16-bit uncompression. so like, 14 is the friendship bracelet that fits everyone's wrist. 15 and 16? some 16-bit-architecture girlies literally cannot, iykyk πŸŽ€


πŸ¦‹ EXAMPLES πŸ¦‹

None. (no examples, just vibes.)


🌈 RATIONALE 🌈

None.


⭐ FUTURE DIRECTIONS ⭐

None.


πŸ‘‘ SEE ALSO πŸ‘‘

  • compress
  • zcat

The Base Definitions volume of POSIX.1‐2017, Chapter 8, Environment Variables, Section 12.2, Utility Syntax Guidelines


Portions of this text are reprinted and reproduced in electronic form from IEEE Std 1003.1-2017, Standard for Information Technology -- Portable Operating System Interface (POSIX), The Open Group Base Specifications Issue 7, 2018 Edition, Copyright (C) 2018 by the Institute of Electrical and Electronics Engineers, Inc and The Open Group. In the event of any discrepancy between this version and the original IEEE and The Open Group Standard, the original IEEE and The Open Group Standard is the referee document. The original Standard can be obtained online at http://www.opengroup.org/unix/online.html .

Any typographical or formatting errors that appear in this page are most likely to have been introduced during the conversion of the source files to man page format. To report such errors, see https://www.kernel.org/doc/man-pages/reporting_bugs.html .


okay so that's the whole page, bestie πŸ’– credit where it's due: IEEE/The Open Group, 2017 β€” they're the ones who brought you UNCOMPRESS(1P), and honestly? we're obsessed with them for it. mwah, bye 🫢✨

πŸ“¦ where this page comes from