mirror of
https://github.com/ouch-org/ouch.git
synced 2025-06-05 02:55:31 +00:00
README update
This commit is contained in:
parent
a0f43b62f7
commit
06c69d4d8f
98
README.md
98
README.md
@ -2,18 +2,17 @@
|
||||
|
||||
<!--  -->
|
||||
|
||||
`ouch` loosely stands for Obvious Unified Compression files Helper.
|
||||
`ouch` stands for **Obvious Unified Compression Helper**, and works on _Linux_, _Mac OS_ and _Windows_.
|
||||
|
||||
It is an easy and painless way of compressing and decompressing files in the terminal.
|
||||
|
||||
Works in `Linux`, `Mac OS` and `Windows`.
|
||||
It is a CLI tool to compress and decompress files that aims to be easy to use.
|
||||
|
||||
<!-- TODO -->
|
||||
<!-- - [Listing files](#Listing-the-elements-of-an-archive) -->
|
||||
|
||||
- [Installation](#Installation)
|
||||
- [Usage](#Usage)
|
||||
- [Decompressing files](#Decompressing-files)
|
||||
- [Compressing files/directories](#Compressing-files-and-directories)
|
||||
- [Installation](#Installation)
|
||||
- [Supported Formats](#Supported-formats)
|
||||
- [Supported operating systems](#Supported-operating-systems)
|
||||
|
||||
@ -24,45 +23,43 @@ Works in `Linux`, `Mac OS` and `Windows`.
|
||||
Run `ouch` and pass compressed files as arguments.
|
||||
|
||||
```sh
|
||||
# Decompress `a.zip`
|
||||
# Decompress 'a.zip'
|
||||
ouch a.zip
|
||||
|
||||
# Decompress multiple files
|
||||
ouch a.zip b.tar.gz
|
||||
```
|
||||
|
||||
Use the `-o/--output` flag to redirect the output of decompressions to a folder.
|
||||
You can redirect the decompression results to a folder with the `-o/--output` flag.
|
||||
|
||||
```sh
|
||||
# Decompress multiple files but inside new_folder
|
||||
ouch a.zip b.tar.gz c.tar.bz2 -o new_folder
|
||||
# Create 'pictures' folder and decompress inside of it
|
||||
ouch 1.tar.gz 2.tar.gz -o pictures
|
||||
```
|
||||
|
||||
### Compressing
|
||||
|
||||
Use the `compress` subcommand.
|
||||
|
||||
Accepts files and folders, and the **last** argument shall be the **output file**.
|
||||
Accepts multiple files and folders, the **last** argument shall be the **output file**.
|
||||
|
||||
```sh
|
||||
# Compress four files into `archive.zip`
|
||||
# Compress four files into 'archive.zip'
|
||||
ouch compress 1 2 3 4 archive.zip
|
||||
|
||||
# Compress folder and video into 'videos.tar.gz'
|
||||
ouch compress videos/ meme.mp4 videos.tar.gz
|
||||
|
||||
# Compress one file using 4 compression formats
|
||||
ouch compress file.txt compressed.gz.xz.bz.zst
|
||||
|
||||
# Compress all the files in current folder
|
||||
ouch compress * files.zip
|
||||
```
|
||||
|
||||
The supplied **output file** shall have a supported compression format, [see the list](#Supported-formats).
|
||||
`ouch` checks for the extensions of the **output file** to decide which formats should be used.
|
||||
|
||||
You can also use the `c` alias for this subcommand.
|
||||
|
||||
```sh
|
||||
# Compress a folder and a file into `videos.tar.xz`
|
||||
ouch c Videos/ funny_meme.mp4 videos.tar.xz
|
||||
|
||||
# Compress three files into a `.tar.bz2` archive
|
||||
ouch c a.mp4 b.jpg c.png files.tar.bz2
|
||||
|
||||
# Compress two folders into a lzma file
|
||||
ouch c src/ target/ build.tar.lz
|
||||
```
|
||||
Check the [list of all file extensions supported](#Supported-formats).
|
||||
|
||||
<!-- ### Listing the elements of an archive
|
||||
|
||||
@ -75,49 +72,40 @@ ouch list videos.tar.xz
|
||||
|
||||
## Installation
|
||||
|
||||
### Installing a binary
|
||||
### Downloading the latest binary
|
||||
|
||||
WARNING: SCRIPT TEMPORARILY DISABLED.
|
||||
|
||||
This script downloads the latest binary and copies it to `/usr/bin`.
|
||||
|
||||
```sh
|
||||
curl -s https://raw.githubusercontent.com/vrmiguel/ouch/master/install.sh | sh
|
||||
```
|
||||
|
||||
### Compiling
|
||||
Install [Rust](rust-lang.org) and [Cargo](https://doc.rust-lang.org/cargo/) via [rustup.rs](https://rustup.rs/).
|
||||
### Installing from source code
|
||||
|
||||
From latest official release:
|
||||
```sh
|
||||
cargo install ouch
|
||||
```
|
||||
For compiling, check [the wiki guide](https://github.com/ouch-org/ouch/wiki/Compiling-and-installing-from-source-code).
|
||||
|
||||
From repository source code:
|
||||
|
||||
```sh
|
||||
git clone https://github.com/vrmiguel/ouch
|
||||
cargo build
|
||||
```
|
||||
|
||||
## Supported formats
|
||||
|
||||
| | .tar | .zip | .tar.\*¹ | .zip.\*² | .bz, .bz2 | .gz | .xz, .lz, .lzma | .7z |
|
||||
|:-------------:|:----:|:----:|:--------:|:--------:|:---------:| --- |:---------------:| --- |
|
||||
| Decompression | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✗ |
|
||||
| Compression | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✗ |
|
||||
| | .tar | .zip | .bz, .bz2 | .gz | .xz, .lz, .lzma | .7z |
|
||||
|:-------------:|:----:|:----:|:---------:| --- |:---------------:| --- |
|
||||
| Decompression | ✓ | ✓ | ✓ | ✓ | ✓ | ✗ |
|
||||
| Compression | ✓ | ✓ | ✓ | ✓ | ✓ | ✗ |
|
||||
|
||||
```
|
||||
Note: .tar.*¹: .tar.gz, .tar.bz, .tar.bz2, .tar.xz, .tar.lz, .tar.lzma, .tar.zip
|
||||
.zip.*²: .zip.gz, .zip.bz, .zip.bz2, .zip.xz, .zip.lz, .zip.lzma, .zip.zip
|
||||
```
|
||||
Note that formats can be chained:
|
||||
- `.tar.gz`
|
||||
- `.tar.xz`
|
||||
- `.tar.gz.xz`
|
||||
- `.tar.gz.gz.gz.gz.gz.gz.gz.gz.gz.gz.gz.gz.gz.gz.gz.gz.gz.gz.lz.lz.lz.lz.lz.lz.lz.lz.lz.lz.bz.bz.bz.bz.bz.bz.bz`
|
||||
- `.gz.xz`
|
||||
- etc...
|
||||
|
||||
<!-- ## Supported operating systems
|
||||
## Contributing
|
||||
|
||||
`ouch` runs on Linux, macOS and Windows 10. Binaries are available on our [Releases](https://github.com/vrmiguel/ouch/releases) page.
|
||||
`ouch` is 100% made out of voluntary work, any small contribution is welcome!
|
||||
|
||||
Binaries are also available at the end of each (successful) [GitHub Actions](https://github.com/vrmiguel/ouch/actions) run for these targets:
|
||||
|
||||
* Linux x86-64 statically linked (musl libc)
|
||||
* macOS x86-64 dynamically linked
|
||||
* Windows 10
|
||||
* Linux ARMv7 dynamically linked (glibc)
|
||||
|
||||
One must be logged into GitHub to access build artifacts. -->
|
||||
- Open an issue.
|
||||
- Open a pr.
|
||||
- Share it to a friend.
|
||||
|
Loading…
x
Reference in New Issue
Block a user