I really enjoy using a command-line interface instead of a graphical user interface, and was wondering if anyone had any solid recommendations for applications that one can use in a terminal window.
I am getting fonder and fonder of xargs. It basically reads some input and appends it to a pre-supplied string. Then executes the newly created string as a command.
Trivial example:
ls -1 | xargs -L1 echo processing
I am finding it quite useful to load and delete a bunch of netapp volume snapshots in a single line:
With xargs (and find), I wish I would've found this sooner:
find test -print0 | xargs -0 file "This allows file names that contain newlines or other types of white space to be correctly interpreted by programs that process the find output. This option corresponds to the -0 option of xargs."
Comments (385) 158 threads
Show all comments
Showing thread 75 of 158
Trivial example:
I am finding it quite useful to load and delete a bunch of netapp volume snapshots in a single line:find test -print0 | xargs -0 file
"This allows file names that contain newlines or other types of white space to be correctly interpreted by programs that process the find output. This option corresponds to the -0 option of xargs."