Shell/Bash: cut last field delimiter Example

By

Shell/Bash Example: This is the "cut last field delimiter" Example. compiled from many sources on the internet by SimpleTutorials.org

cut last field delimiter

Use rev command altogether with cut command as follows:
echo "1 2 3 4 5" | rev | cut -d ' ' -f '2-' | rev
#rev reverses string, then you cut from 2th field to end and reverse back


* Summary: This "cut last field delimiter" Shell/Bash Example is compiled from the internet. If you have any questions, please leave a comment. Thank you!

Others