Commonly used · Packaging and compression
tar: Pack, view and restore archives
Syntax
tar -[cxt][zv]f archive [-C directory] [path…]Options
-c- create
-x- Unpack
-t- list items
-f- archive file
-z- Teaching gzip tag
-v- Show entries
-C- Switch archive working directory
Examples
tar -czf project.tar.gz projectsUsage and sandbox support
Sandbox archives store file snapshots, not actual tar/gzip binaries.
Hands-on exercises
- Create a delivery package for the projectEveryday
- Check before unpackingEveryday
- Restore to separate directoryAdvanced
- Pack relative path from specified directoryAdvanced
- Delivery Challenges ④ Backup ConfigurationAdvanced
- Precise selection of delivery documentsMaster