NULIB2(1)
๐ NULIB2 ๐ (that's section 1 of the manual pages, bestie)
okay so you found nulib2 and you're like "what is this" โ dw, I got you. this is a General Commands Manual page and I'm about to spill all the tea. โจ
๐ธ NAME ๐ธ
nulib2 โ package and compress (archive) files ๐
๐ฆ SYNOPSIS ๐ฆ
nulib2 -command[modifiers] archive [ filenames ]
โจ DESCRIPTION โจ
so nulib2 is a disk and file archiver for NuFX (ShrinkIt) files. it can add files to and extract files from .SHK, .BXY, .SEA (as created by GS/ShrinkIt), and .BSE files. plus โ and this is the slay part โ it can also extract files from .BNY and .BQY Binary II archives. ๐
when you're extracting, testing, or listing the contents of an archive, you can literally just pass - as the archive name and it'll read the archive from stdin. (but heads up: if that archive is Binary II, you must specify the -b flag. no cap.) ๐ซถ
filenames are considered case-sensitive</>, so likeโฆ be normal about your capital letters. ๐
this man page is just a lil summary of the available options, fr fr. for the full documentation and the latest versions, go visit http://www.nulib.com/. ๐ง
๐ OPTIONS ๐
-hโ get verbose help output. ask and ye shall receive. โจ-aโ add files to an archive. if the archive doesn't exist yet, a brand new one gets created (main character energy tbh). you must give it the list of files to add.-dโ delete files from an archive. the set of files to delete must be provided. bye bestie ๐-iโ integrity test. if you don't list any files, then every single file in the archive gets tested. vibe check for your data. ๐ฉบ-pโ pipe extraction. all extracted files get written to stdout instead of a file on disk, and the normal archive progress messages are suppressed. quiet + mysterious. ๐คซ-tโ table of contents. gives you a simple list of the files in the archive, one per line. ๐-vโ verbose table of contents. output that's similar to what ShrinkIt displays. extra, in a good way. ๐-xโ extract files from an archive. if you don't list any files, all of them get extracted. ๐
๐ MODIFIERS ๐
-cโ comments. when extracting, comments get displayed. when adding, you'll be prompted to enter a one-line comment for every single file. (yes, every one. bring snacks.) ๐ฌ-eโ preserve ProDOS file types. see the ProDOS File Type Preservation document on http://www.nulib.com/ for the deets on how this actually works. ๐-eeโ preserve file types, but using extended names. a file extension gets appended to extracted files. super useful on operating systems like Windows, where filename extensions are important. when adding files,nulib2will try to guess at the correct file types by examining the filename extension. it's giving psychic ๐ฎ-fโ freshen files. when adding, files in the archive that are older than the files on disk get "freshened", which means no new files are added, and files that are the same age or newer aren't touched at all. works similarly when extracting.-jโ junk directory names. only the filename is kept; the rest of the pathname gets thrown away. empty directories aren't stored. works when adding or extracting. ๐๏ธ-kโ store files as disk images. files that are a multiple of 512 bytes will be added as disk images rather than normal files. this does not override the-eflag.-lโ auto-convert text files. a reasonably smart algorithm is used to identify which files are text and which aren't during extraction. it then converts whatever EOL indicator is being used by the text file into something appropriate for the current system. ๐ช-llโ auto-convert all files. every file being extracted is considered text, and will be converted. > don't use this unless you're sure you need it. like, actually sure. fr.-rโ recurse into subdirectories. when adding, this causesnulib2to descend into subdirectories and store all of the files found. when extracting, testing, or deleting, this causes the files listed to match against all records whose prefix matches โ so you can extract, test, or delete entire subdirectories from the archive. it's giving tree traversal ๐ณ-uโ update files. when adding, files in the archive that are older than the files on disk get updated. files in the archive that are the same age or newer aren't touched. new files will be added. works similarly when extracting. โจ-bโ Binary II. forces NuLib2 to treat the archive as Binary II. useful for opening NuFX-in-BNY archives (.BXY) if you want to strip the wrapper off. you must specify this for Binary II archives on stdin.-0โ don't use compression. files added will be stored without any compression. (note that's dash-zero, not dash-oh. yes this has tripped people up, no you're not alone.) ๐-zโ use "deflate" compression. this option is only available if libz was linked against. > archives created with this algorithm will not be usable on an Apple II. ๐-zzโ use "bzip2" compression. this option is only available if libbz2 was linked against. > archives created with this algorithm will not be usable on an Apple II. ๐
๐ EXAMPLES ๐
a simple example:
nulib2 a foo.shk *
this creates the archive foo.shk (assuming it doesn't exist) and stores all of the files in the current directory in it, in compressed form. easy. iconic. ๐
if you wanted to add all the files in the current directory, as well as all files in all subdirectories, you could use:
nulib2 ar foo.shk *
to recursively descend into the directory tree. ๐ณ
using the command:
nulib2 xe foo.shk
would extract all files from foo.shk, preserving ProDOS file types. and if you then used the command:
nulib2 aer foo.shk *
you would add the files, preserving the file types of anything that was extracted with the -e flag set. see how it all connects? obsessed. ๐ฅ
a handy way to look at text documents is to use:
nulib2 xeel foo.shk
to convert end-of-line terminators (e.g. CRLF to LF) as the files are being extracted. the -ee flag adds .TXT to all files with a ProDOS file type of TXT ($04). ๐
๐ SEE ALSO ๐
compress(1), tar(1), zip(1), unzip(1)
๐ BUGS ๐
Nah.
๐ AUTHOR ๐
Copyright (C) 2007 by Andy McFadden. All Rights Reserved.
and that's the whole page bestie!! ๐ซถ this was NULIB2(1) from 08 Feb 2003</> โ yes it's giving vintage, yes it still slays. go archive something. ๐โจ๐
๐ฆ where this page comes from
- debian bookworm: nulib2 3.1.0-5 ยท BSD-3-Clause
- debian trixie: nulib2 3.1.0-5 ยท BSD-3-Clause
- ubuntu jammy: nulib2 3.1.0-5 ยท BSD-3-Clause
- ubuntu noble: nulib2 3.1.0-5 ยท BSD-3-Clause
- ubuntu resolute: nulib2 3.1.0-5build1 ยท BSD-3-Clause
- ubuntu stonking: nulib2 3.1.0-5build1 ยท BSD-3-Clause
- Copyright (C) 2000-2007 by Andy McFadden. All Rights Reserved
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms