gustavorv86 / cutter

All-in-one console tool for text manipulation, such as grep, sed, cut, tr, awk etc.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

cutter

All-in-one console tool for text manipulation, such as grep, sed, cut, tr, awk etc.

Examples

Get all system users:
$ cat /etc/passwd | cutter --split=":" --format="{0}"

Get all system users and homes:
$ cat /etc/passwd | cutter --split=":" --format="{0} {5}"

Get all numbers of the current kernel version:
$ uname -a | cutter --split --format="{6}" --search-and-replace=/-/./ --split="." --format="{0} {1} {2} {3}"

Get interface names:
$ ip link | cutter --filter="UP" --search-and-replace=/:// --split --format="{1}"

Get all IPv4 addresses:
$ ip addr | cutter --filter="inet " --search-and-replace="&/& &" --split --format="{1}"

Get all running process and command line:
$ ps aux | cutter --nfilter="[" --nfilter="/cutter " --nfilter="ps aux" --substring=/65//

About

All-in-one console tool for text manipulation, such as grep, sed, cut, tr, awk etc.

License:GNU General Public License v3.0


Languages

Language:Python 89.5%Language:Makefile 6.7%Language:Batchfile 3.7%