aki-resort sort lines of text.
aki-resort sort lines of text. You can use regex to specify the KEY.
text
aki-resort --help
```text Usage: aki-resort [options]
sort lines of text.
Ordering options:
-r, --reverse reverse the result of comparisons
--according-to
Other options:
-e, --regex
-H, --help display this help and exit -V, --version display version information and exit ```
text
cargo install aki-resort
text
cargo deb
and install .deb into your local repository of debian package.
The input data used in this example looks like this:
cat file1.txt
result output:
ABCDEFG:33:abc
OPQRSTU:222:opq
VWXYZ:4:vwx
HIJKLMN:1111:hij
This sort via utf-8 code.
command line:
cat file1.txt | aki-resort
result output:
ABCDEFG:33:abc
HIJKLMN:1111:hij
OPQRSTU:222:opq
VWXYZ:4:vwx
This sort via 1st chunk of numeric character according to numeric.
command line:
cat file1.txt | aki-resort -e "[0-9]+" --according-to numeric
result output:
VWXYZ:4:vwx
ABCDEFG:33:abc
OPQRSTU:222:opq
HIJKLMN:1111:hij
See [fn execute()
] for this library examples.