MAKESELF(1)

πŸ’– MAKESELF πŸ’–

okay bestie, sit down, hydrate, because i'm about to tell you about the most iconic little utility in the whole General Commands Manual lineup. it's called makeself, and it makes self-extractable archives. no cap.


✨ NAME ✨

makeself β€” an utility to generate self-extractable archives. that's it. that's the whole vibe. πŸ’…


🌸 SYNTAX 🌸

makeself [options] archive_dir file_name label [startup_script] [args]

πŸ¦‹ DESCRIPTION πŸ¦‹

so this program is a free (GPL) shell utility designed to create self-extractable compressed archives from a directory. the resulting file? it literally looks like a plain shell script. and you can just... launch it as is. like, that's the whole trick, and it's giving genius energy fr fr. 🧚

when you run it, the archive uncompresses itself to a temporary directory, and then an optional arbitrary command gets executed β€” think an installation script, y'know, the classic move.

and here's the part that's lowkey important: makeself archives also include checksums for integrity self-validation β€” that's CRC and/or MD5/SHA256 checksums. so the archive can check itself. main character behavior honestly. πŸ‘‘


πŸ’… OPTIONS πŸ’…

the following options are supported:

  • -v, --version β€” prints out the makeself version number and dips out. that's all. exit stage left. ✨
  • -h, --help β€” print out help information. your little cheat sheet.
  • --tar-quietly β€” suppress verbose output from the tar command. shhh. 🀫
  • --quiet β€” do not print any messages other than errors. silence mode activated.
  • --gzip β€” compress using gzip (this is the default if detected). the reliable friend. πŸ’–
  • --bzip2 β€” compress using bzip2.
  • --bzip3 β€” compress using bzip3.
  • --pbzip2 β€” compress using pbzip2.
  • --xz β€” compress using xz.
  • --lzo β€” compress using lzop.
  • --lz4 β€” compress using lz4.
  • --pigz β€” compress using pigz.
  • --zstd β€” compress using zstd.
  • --base64 β€” encode the archive to ASCII in Base64 format instead of compressing (the base64 command is required for this btw).
  • --gpg-encrypt β€” encrypt the archive using GPG. heads up, this will prompt for a password to encrypt with. keep it secret, keep it safe. πŸ”
  • --ssl-encrypt β€” encrypt the archive using OpenSSL. also prompts for a password to encrypt with.
  • --keep-umask β€” keep the umask set to shell default, rather than overriding when executing the self-extracting archive.
  • --compress β€” compress using the UNIX compress command. vintage vibes.
  • --nocomp β€” do not compress the data. raw. unbothered. unbothered and raw. πŸ’€
  • --complevel lvl β€” specify the compression level for gzip, bzip2, pbzip2, xz, zstd, lzo or lz4. defaults to 9 (max effort, slay).
  • --comp-extra opt β€” append more options to the compressor's command line.
  • --threads num β€” specify the number of threads to be used by compressors that support parallelization. multi-threaded and multitasking, queen behavior. πŸ‘‘
  • --tar-format opt β€” specify the tar archive format (default is ustar); you may use any value accepted by your tar command (such as posix, v7, etc).
  • --tar-extra opt β€” append more options to the tar command line.
  • --notemp β€” the archive will create archive_dir in the current directory and uncompress in ./archive_dir.
  • --copy β€” upon extraction, the archive will first copy itself to a temporary directory.
  • --append β€” append more files to an existing makeself archive. note that the label and startup scripts will then be ignored. they're just not invited to this party bestie. πŸ™ˆ
  • --current β€” files will be extracted to the current directory. both --current and --target dir imply --notemp. iykyk.
  • --target dir β€” extract directly to a target directory. the directory path can be either absolute or relative.
  • --header file β€” specify location of the header script.
  • --help-header file β€” add a header to the archive's help output.
  • --preextract file β€” specify a pre-extraction script. runs before the extraction, as the name suggests, we been knew.
  • --cleanup file β€” specify a cleanup script that executes on interrupt and when finished successfully. tidy queen. πŸŽ€
  • --follow β€” follow the symlinks in the archive.
  • --noprogress β€” do not show the progress during the decompression. no little bar for you.
  • --nooverwrite β€” do not extract the archive if the target directory already exists. boundaries. πŸ’…
  • --nox11 β€” disable automatic spawn of an xterm if running in X11.
  • --nowait β€” do not wait for user input after executing embedded program from an xterm.
  • --nomd5 β€” do not create a MD5 checksum for the archive.
  • --sha256 β€” adds a SHA256 checksum for the archive. ✨
  • --nocrc β€” do not create a CRC32 checksum for the archive.
  • --lsm file β€” LSM file describing the package.
  • --license file β€” append a license file.
  • --packaging-date date β€” use provided string as the packaging date instead of the current date. time travel, but make it legal.

🌈 ENVIRONMENT 🌈

  • SETUP_NOCHECK β€” if set to 1, then checksum validation will be skipped.
okay so real talk: that means the integrity check just doesn't happen. so like, know what you're doing, bestie. πŸ’€

⭐ EXAMPLES ⭐

here's an example, assuming the user has a package image stored in a /home/joe/mysoft, and he wants to generate a self-extracting package named mysoft.sh, which will launch the "setup" script initially stored in /home/joe/mysoft:

makeself.sh /home/joe/mysoft mysoft.sh "Joe's Nice Software Package"
./setup

and here is also how i created the makeself.run archive which contains the Makeself distribution:

makeself.sh --notemp makeself makeself.run "Makeself by Stephane Peter"
echo "Makeself has extracted itself"

🫢 AUTHORS 🫢

Makeself has been written by Stephane Peter <megastep@megastep.org>. 🧚

this man page was originally written by Bartosz Fenski <fenio@o2.pl> for the Debian GNU/Linux distribution (but it may be used by others). generous icon behavior honestly.


okay that's the whole page, you ate it, you understood it, go make some self-extracting archives and be the main character of your own shell script. 🌸

this was version 2.5.0, and yeah β€” this is the MAKESELF(1) page. mwah. πŸ’–

πŸ“¦ where this page comes from