The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #5 (permalink)  
Old 06-05-2008
radoulov's Avatar
radoulov radoulov is offline Forum Staff  
addict
  
 

Join Date: Jan 2007
Location: Варна, България / Milano, Italia
Posts: 2,867
Code:
df -k|cat
(...)

Note: if you redirect or pipe to other process, you don't need cat:

Code:
$ df -k /
Filesystem            kbytes    used   avail capacity  Mounted on
/dev/vx/dsk/bootdg/rootvol
                     5043518 4735581  257502    95%    /
$ df -k /|cat
Filesystem            kbytes    used   avail capacity  Mounted on
/dev/vx/dsk/bootdg/rootvol 5043518 4735581  257502    95%    /
$ df -k />t;cat t
Filesystem            kbytes    used   avail capacity  Mounted on
/dev/vx/dsk/bootdg/rootvol 5043518 4735581  257502    95%    /
Or, with some shells (if you don't mind the (ba|k)sh: __: part ):

Code:
${__?"$(df -k)"}
or:

Code:
printf "%s\n" "$(df -k)"

Last edited by radoulov; 06-05-2008 at 10:04 AM..