[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Help-bash] variable assign preceding script
From: |
Greg Wooledge |
Subject: |
Re: [Help-bash] variable assign preceding script |
Date: |
Thu, 2 Jun 2016 11:10:04 -0400 |
User-agent: |
Mutt/1.4.2.3i |
On Thu, Jun 02, 2016 at 11:04:56PM +0800, Wu Shuangrong wrote:
> Thanks for your prompt reply.
> I have checked this, it really behaves the way as you said.
> Does this only occur for script files? What about binary command?
Commands like sed, grep, awk that aren't shells do not use the IFS
variable at all. Awk has both input and output field separators,
but they are specified with different commands/options. E.g. to
specify an awk input field separator of : from the command line:
$ head -n 1 /etc/passwd | awk -F: '{print $1}'
root