mirror of
https://github.com/uutils/tar.git
synced 2026-06-10 16:14:35 -07:00
42a1c3422262b7288e2fa77dd1b082306fef8d41
Support traditional key syntax (for example `tar cvf archive.tar file`) by rewriting a leading key operand into clap-compatible short options before argument parsing. - detect valid keystrings in argv[1] - expand key letters into `-<opt>` arguments - consume operands for `f` and `b` in key order - forward `-b` (currently unsupported) so key/dash forms fail consistently - update usage text to document key syntax - add unit tests for key detection/expansion - add integration tests for create/extract parity and `-b` failure parity Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
tar
Rust reimplementation of the tar utility.
Installation
Ensure you have Rust installed on your system. You can install Rust through rustup.
Clone the repository and build the project using Cargo:
git clone https://github.com/uutils/tar.git
cd tar
cargo build --release
cargo run --release
Testing
The tar application has a focused testing philosophy that separates concerns between the application (CLI interface, error handling, user experience) and the underlying tar-rs library (archive format correctness, encoding, permissions).
See tests/README.md for comprehensive documentation.
# Run all tests
cargo test --all
# Run specific test
cargo test test_create_single_file
License
tar is licensed under the MIT License - see the LICENSE file for details
Languages
Rust
72.4%
Python
19.7%
Shell
7.9%