[{"data":1,"prerenderedAt":619},["ShallowReactive",2],{"navigation_docs":3,"-guide-cli":84,"-guide-cli-surround":614},[4,48],{"title":5,"path":6,"stem":7,"children":8,"icon":47},"Guide","\u002Fguide","1.guide\u002F01.index",[9,11,15,19,23,27,31,35,39,43],{"title":10,"path":6,"stem":7},"Getting Started",{"title":12,"path":13,"stem":14},"Compressing","\u002Fguide\u002Fcompressing","1.guide\u002F02.compressing",{"title":16,"path":17,"stem":18},"Containers","\u002Fguide\u002Fcontainers","1.guide\u002F03.containers",{"title":20,"path":21,"stem":22},"Checksums","\u002Fguide\u002Fchecksums","1.guide\u002F04.checksums",{"title":24,"path":25,"stem":26},"Identify and peel","\u002Fguide\u002Fidentify","1.guide\u002F05.identify",{"title":28,"path":29,"stem":30},"Limits","\u002Fguide\u002Flimits","1.guide\u002F06.limits",{"title":32,"path":33,"stem":34},"CLI","\u002Fguide\u002Fcli","1.guide\u002F07.cli",{"title":36,"path":37,"stem":38},"Agents","\u002Fguide\u002Fagents","1.guide\u002F08.agents",{"title":40,"path":41,"stem":42},"Custom formats","\u002Fguide\u002Fcustom","1.guide\u002F09.custom",{"title":44,"path":45,"stem":46},"Playground","\u002Fguide\u002Fplayground","1.guide\u002F10.playground","i-lucide-book-open",{"title":49,"path":50,"stem":51,"children":52,"icon":83},"Formats","\u002Fformats","2.formats\u002F00.index",[53,55,59,63,67,71,75,79],{"title":54,"path":50,"stem":51},"Every format",{"title":56,"path":57,"stem":58},"deflate","\u002Fformats\u002Fdeflate","2.formats\u002F01.deflate",{"title":60,"path":61,"stem":62},"bzip2","\u002Fformats\u002Fbzip2","2.formats\u002F02.bzip2",{"title":64,"path":65,"stem":66},"LZMA","\u002Fformats\u002Flzma","2.formats\u002F03.lzma",{"title":68,"path":69,"stem":70},"Zstandard","\u002Fformats\u002Fzstd","2.formats\u002F04.zstd",{"title":72,"path":73,"stem":74},"Brotli","\u002Fformats\u002Fbrotli","2.formats\u002F05.brotli",{"title":76,"path":77,"stem":78},"LZ4","\u002Fformats\u002Flz4","2.formats\u002F06.lz4",{"title":80,"path":81,"stem":82},"Unix compress","\u002Fformats\u002Flzw","2.formats\u002F07.lzw","i-lucide-library",{"id":85,"title":32,"body":86,"description":606,"extension":607,"links":608,"meta":609,"navigation":611,"path":33,"seo":612,"stem":34,"__hash__":613},"docs\u002F1.guide\u002F07.cli.md",{"type":87,"value":88,"toc":599},"minimark",[89,94,138,164,167,264,275,421,424,480,483,491,501,504,517,523,526,532,554,557,579,585,595],[90,91,93],"h2",{"id":92},"install-or-run-it","Install or run it",[95,96,101],"pre",{"className":97,"code":98,"language":99,"meta":100,"style":100},"language-bash shiki shiki-themes compressions compressions compressions","npx @agntn\u002Fcompressions identify mystery.bin\npnpm add -g @agntn\u002Fcompressions\n","bash","",[102,103,104,123],"code",{"__ignoreMap":100},[105,106,109,113,117,120],"span",{"class":107,"line":108},"line",1,[105,110,112],{"class":111},"sK71F","npx",[105,114,116],{"class":115},"shU9J"," @agntn\u002Fcompressions",[105,118,119],{"class":115}," identify",[105,121,122],{"class":115}," mystery.bin\n",[105,124,126,129,132,135],{"class":107,"line":125},2,[105,127,128],{"class":111},"pnpm",[105,130,131],{"class":115}," add",[105,133,134],{"class":115}," -g",[105,136,137],{"class":115}," @agntn\u002Fcompressions\n",[139,140,141,142,145,146,145,149,145,152,155,156,159,160,163],"p",{},"Five commands: ",[102,143,144],{},"compress",", ",[102,147,148],{},"decompress",[102,150,151],{},"identify",[102,153,154],{},"list"," and ",[102,157,158],{},"mcp",". Every one takes a file, or ",[102,161,162],{},"-"," for stdin.",[90,165,166],{"id":144},"Compress",[95,168,170],{"className":97,"code":169,"language":99,"meta":100,"style":100},"compressions compress deflate notes.txt --container gzip --level 9 > notes.txt.gz\ncompressions compress lzma notes.txt --container xz --check sha256 > notes.txt.xz\necho -n \"hello world!\" | compressions compress bzip2 - --to base64\n",[102,171,172,205,232],{"__ignoreMap":100},[105,173,174,177,180,183,186,189,192,195,198,202],{"class":107,"line":108},[105,175,176],{"class":111},"compressions",[105,178,179],{"class":115}," compress",[105,181,182],{"class":115}," deflate",[105,184,185],{"class":115}," notes.txt",[105,187,188],{"class":115}," --container",[105,190,191],{"class":115}," gzip",[105,193,194],{"class":115}," --level",[105,196,197],{"class":115}," 9",[105,199,201],{"class":200},"skH_V"," >",[105,203,204],{"class":115}," notes.txt.gz\n",[105,206,207,209,211,214,216,218,221,224,227,229],{"class":107,"line":125},[105,208,176],{"class":111},[105,210,179],{"class":115},[105,212,213],{"class":115}," lzma",[105,215,185],{"class":115},[105,217,188],{"class":115},[105,219,220],{"class":115}," xz",[105,222,223],{"class":115}," --check",[105,225,226],{"class":115}," sha256",[105,228,201],{"class":200},[105,230,231],{"class":115}," notes.txt.xz\n",[105,233,235,238,241,244,247,250,252,255,258,261],{"class":107,"line":234},3,[105,236,237],{"class":111},"echo",[105,239,240],{"class":115}," -n",[105,242,243],{"class":115}," \"hello world!\"",[105,245,246],{"class":200}," |",[105,248,249],{"class":111}," compressions",[105,251,179],{"class":115},[105,253,254],{"class":115}," bzip2",[105,256,257],{"class":115}," -",[105,259,260],{"class":115}," --to",[105,262,263],{"class":115}," base64\n",[139,265,266,267,270,271,274],{},"Raw compressed bytes never go to a terminal. Redirect them, or pass ",[102,268,269],{},"--to base64"," or ",[102,272,273],{},"--to hex",".",[276,277,278,291],"table",{},[279,280,281],"thead",{},[282,283,284,288],"tr",{},[285,286,287],"th",{},"Flag",[285,289,290],{},"Takes",[292,293,294,328,338,355,381,391,401],"tbody",{},[282,295,296,302],{},[297,298,299],"td",{},[102,300,301],{},"--container",[297,303,304,305,145,308,145,311,314,315,145,318,321,322,145,325],{},"deflate ",[102,306,307],{},"raw",[102,309,310],{},"zlib",[102,312,313],{},"gzip",". lzma ",[102,316,317],{},"alone",[102,319,320],{},"xz",". lz4 ",[102,323,324],{},"frame",[102,326,327],{},"legacy",[282,329,330,335],{},[297,331,332],{},[102,333,334],{},"--level",[297,336,337],{},"deflate 0 to 9, lzma 0 to 9, bzip2 1 to 9",[282,339,340,348],{},[297,341,342,145,345],{},[102,343,344],{},"--name",[102,346,347],{},"--mtime",[297,349,350,351,354],{},"deflate with ",[102,352,353],{},"--container gzip",": the header fields",[282,356,357,362],{},[297,358,359],{},[102,360,361],{},"--check",[297,363,364,365,368,369,145,372,145,375,145,378],{},"lzma with ",[102,366,367],{},"--container xz",": ",[102,370,371],{},"none",[102,373,374],{},"crc32",[102,376,377],{},"crc64",[102,379,380],{},"sha256",[282,382,383,388],{},[297,384,385],{},[102,386,387],{},"--checksum",[297,389,390],{},"lz4 frame: XXH32 of the content, on by default",[282,392,393,398],{},[297,394,395],{},[102,396,397],{},"--bits",[297,399,400],{},"lzw: the widest code, 10 to 16",[282,402,403,411],{},[297,404,405,145,408],{},[102,406,407],{},"--from",[102,409,410],{},"--to",[297,412,413,145,415,270,418],{},[102,414,307],{},[102,416,417],{},"hex",[102,419,420],{},"base64",[90,422,423],{"id":148},"Decompress",[95,425,427],{"className":97,"code":426,"language":99,"meta":100,"style":100},"compressions decompress deflate notes.txt.gz --container gzip\necho 1f8b08000000000000ffcb48cdc9c95728cf2fca495104006dc2b4030c000000 \\\n  | compressions decompress deflate - --container gzip --from hex\n",[102,428,429,446,457],{"__ignoreMap":100},[105,430,431,433,436,438,441,443],{"class":107,"line":108},[105,432,176],{"class":111},[105,434,435],{"class":115}," decompress",[105,437,182],{"class":115},[105,439,440],{"class":115}," notes.txt.gz",[105,442,188],{"class":115},[105,444,445],{"class":115}," gzip\n",[105,447,448,450,453],{"class":107,"line":125},[105,449,237],{"class":111},[105,451,452],{"class":115}," 1f8b08000000000000ffcb48cdc9c95728cf2fca495104006dc2b4030c000000",[105,454,456],{"class":455},"s38Sx"," \\\n",[105,458,459,462,464,466,468,470,472,474,477],{"class":107,"line":234},[105,460,461],{"class":200},"  |",[105,463,249],{"class":111},[105,465,435],{"class":115},[105,467,182],{"class":115},[105,469,257],{"class":115},[105,471,188],{"class":115},[105,473,191],{"class":115},[105,475,476],{"class":115}," --from",[105,478,479],{"class":115}," hex\n",[139,481,482],{},"What the stream says about itself goes to stderr, the bytes to stdout:",[95,484,489],{"className":485,"code":487,"language":488,"meta":100},[486],"language-text","os: 255\nmembers: 1\nhello world!\n","text",[102,490,487],{"__ignoreMap":100},[139,492,493,496,497,500],{},[102,494,495],{},"--limit"," caps the output, ",[102,498,499],{},"--partial"," writes what came out before the damage. zstd and brotli decompress here too.",[90,502,503],{"id":151},"Identify",[95,505,507],{"className":97,"code":506,"language":99,"meta":100,"style":100},"compressions identify mystery.bin\n",[102,508,509],{"__ignoreMap":100},[105,510,511,513,515],{"class":107,"line":108},[105,512,176],{"class":111},[105,514,119],{"class":115},[105,516,122],{"class":115},[95,518,521],{"className":519,"code":520,"language":488,"meta":100},[486],"100 deflate --container gzip  starts with its magic number; checksum matches; decodes to the last byte; decompresses to readable text  \"hello world!\"\n",[102,522,520],{"__ignoreMap":100},[139,524,525],{},"One line per candidate: the score, the format, the flag that reads it, the reasons, a preview. Copy the middle and you have the decompress command. When nothing fits, it says so, and names the archive the bytes look like.",[139,527,528,531],{},[102,529,530],{},"--peel"," takes off every layer, lists them on stderr and writes the innermost bytes to stdout:",[95,533,535],{"className":97,"code":534,"language":99,"meta":100,"style":100},"compressions identify nested.bin --peel > inner.txt\n",[102,536,537],{"__ignoreMap":100},[105,538,539,541,543,546,549,551],{"class":107,"line":108},[105,540,176],{"class":111},[105,542,119],{"class":115},[105,544,545],{"class":115}," nested.bin",[105,547,548],{"class":115}," --peel",[105,550,201],{"class":200},[105,552,553],{"class":115}," inner.txt\n",[90,555,556],{"id":154},"List",[95,558,560],{"className":97,"code":559,"language":99,"meta":100,"style":100},"compressions list\ncompressions list deflate\n",[102,561,562,569],{"__ignoreMap":100},[105,563,564,566],{"class":107,"line":108},[105,565,176],{"class":111},[105,567,568],{"class":115}," list\n",[105,570,571,573,576],{"class":107,"line":125},[105,572,176],{"class":111},[105,574,575],{"class":115}," list",[105,577,578],{"class":115}," deflate\n",[95,580,583],{"className":581,"code":582,"language":488,"meta":100},[486],"deflate (deflate)\nLZ77 with Huffman codes: gzip files, zlib streams, PNG, HTTP and ZIP entries\nstandard  RFC 1951\nwrites    yes\ncontainer raw      raw deflate\ncontainer zlib     zlib, .zz .zlib, checksum Adler-32\ncontainer gzip     gzip, .gz .tgz, magic 1f8b08, checksum CRC-32\n--container  raw deflate, a zlib stream or a gzip file (raw, zlib, gzip) (decompress too)\n--level      0 stores, 1 is fastest, 9 is smallest (0 to 9)\n--name       File name in the gzip header [gzip]\n--mtime      Modification time in the gzip header, Unix seconds; 0 leaves it out (0 to 4294967295) [gzip]\n",[102,584,582],{"__ignoreMap":100},[139,586,587,590,591,594],{},[102,588,589],{},"compressions mcp"," starts the MCP server. ",[592,593,36],"a",{"href":37}," has the rest.",[596,597,598],"style",{},"html pre.shiki code .sK71F, html code.shiki .sK71F{--shiki-light:var(--shiki-token-function);--shiki-default:var(--shiki-token-function);--shiki-dark:var(--shiki-token-function)}html pre.shiki code .shU9J, html code.shiki .shU9J{--shiki-light:var(--shiki-token-string);--shiki-default:var(--shiki-token-string);--shiki-dark:var(--shiki-token-string)}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .skH_V, html code.shiki .skH_V{--shiki-light:var(--shiki-token-keyword);--shiki-default:var(--shiki-token-keyword);--shiki-dark:var(--shiki-token-keyword)}html pre.shiki code .s38Sx, html code.shiki .s38Sx{--shiki-light:var(--ui-text-highlighted);--shiki-default:var(--ui-text-highlighted);--shiki-dark:var(--ui-text-highlighted)}",{"title":100,"searchDepth":125,"depth":125,"links":600},[601,602,603,604,605],{"id":92,"depth":125,"text":93},{"id":144,"depth":125,"text":166},{"id":148,"depth":125,"text":423},{"id":151,"depth":125,"text":503},{"id":154,"depth":125,"text":556},"compress and decompress and identify and list from the terminal. Files or stdin in raw bytes or hex or base64","md",null,{"icon":610},"i-lucide-terminal",true,{"title":32,"description":606},"PEUKMFWI6UaOC2oc15vLXYKu9sOKMojZiSDBjkOG2uA",[615,617],{"title":28,"path":29,"stem":30,"description":616,"children":-1},"An output limit so a bomb stays small and partial reads for streams that break halfway",{"title":36,"path":37,"stem":38,"description":618,"children":-1},"The same tools over MCP and Pi and OMP and the AI SDK. What they take and what they refuse and what the model reads back",1791071143920]