9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: Kris Maglione <bsdaemon@comcast.net>
To: 9fans@cse.psu.edu
Subject: Re: [9fans] name=`{cat foo}
Date: Sat, 26 May 2007 22:23:58 -0400	[thread overview]
Message-ID: <20070527022358.GA48294@kris.home> (raw)
In-Reply-To: <41026BEC-865B-4D05-8144-15F2ED75F01D@ar.aichi-u.ac.jp>

[-- Attachment #1: Type: text/plain, Size: 448 bytes --]

On Sun, May 27, 2007 at 10:49:52AM +0900, arisawa@ar.aichi-u.ac.jp wrote:
> I want to have a shell variable such as:
> 	name='abc    def'
>
> How to do?

You could start by reading the paper or the man page.

for 'abc    def':

ifs='
' { name = `{cat foo} }

for 'abc    def
', or 'abc    def' if you'd used 'echo -n':

ifs=() { name = `{cat foo} }

-- 
Kris Maglione

Bad law is more likely to be supplemented than repealed.

[-- Attachment #2: Type: application/pgp-signature, Size: 194 bytes --]

  reply	other threads:[~2007-05-27  2:23 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-05-27  1:49 arisawa
2007-05-27  2:23 ` Kris Maglione [this message]
2007-05-27  3:04   ` arisawa

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20070527022358.GA48294@kris.home \
    --to=bsdaemon@comcast.net \
    --cc=9fans@cse.psu.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).