LinuxCommandLibrary

xar

Extensible archive format tool

TLDR

Create archive

$ xar -cf [archive.xar] [files]
copy
Extract archive
$ xar -xf [archive.xar]
copy
List contents
$ xar -tf [archive.xar]
copy
Verbose extraction
$ xar -xvf [archive.xar]
copy
Extract to directory
$ xar -xf [archive.xar] -C [directory]
copy

SYNOPSIS

xar [-c] [-x] [-t] [-f archive] [options] [files]

DESCRIPTION

xar (eXtensible ARchive) creates and extracts archives using a format developed by Apple, primarily used for macOS installer packages. The format uses an XML-based table of contents that supports rich metadata and multiple compression algorithms per file.
The archive format also includes signature support for code signing and integrity verification. While primarily associated with macOS, xar is available on Linux for working with macOS package files and other XAR archives.

PARAMETERS

-c

Create archive.
-x
Extract archive.
-t
List contents.
-f FILE
Archive file.
-v
Verbose.
-C DIR
Target directory.

CAVEATS

macOS oriented. Less common on Linux. XML overhead.

HISTORY

xar (eXtensible ARchive) was developed by Apple for macOS installer packages.

SEE ALSO

tar(1), pkgutil(1), ar(1)

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community