use awk to extract all column except first column or speciifed column

Sed & Awk is one of my favorite command when it comes to file data processing using cli.

Here is a simple example in which we want to display all columns but except the first one.
case - want to save output of history command without numeric serial.

$ history | awk '{first = $1; $1 = ""; print $0 }' > history.txt

And done.

Comments

Popular posts from this blog

Running cockpit behind nginx reverse proxy with nginx ssl and cockpit non ssl

using libguestfs virt-customize tool to modify qcow2 image and reset root password.

Setup VOD streaming server with nginx using RTMP on Ubuntu 18.04