Skip to content

Latest commit

 

History

History
39 lines (32 loc) · 643 Bytes

'bsdtar'.md

File metadata and controls

39 lines (32 loc) · 643 Bytes

bsdtar

-c compress

  • -J xz compression
  • -j bzip2 compression
  • -lzma lzma compression
  • -z gzip compression

-x expand
-v verbose
-p keep files permissions
-f target file (must be right before file)

Expand to current directory

bsdtar -xf file.tar.xz

Expand to target

mkdir target
bsdtar -xf file.tar.xz -C target

Expand sub directory

bsdtar -xf file.tar.xz -C target subdirectory/

Expand not include root directory of compressed.file to target

bsdtar -xf file.tar.xz --strip 1 -C target

Compress to xz

bsdtar -cJf file.tar.xz files