Re: how to insert <CR> in ratpoison -c colon command

clemens fischer <[email protected]>
Newsgroups gmane.comp.window-managers.ratpoison.devel
Message-ID <[email protected]>
On Wed-2009/12/02-17:08 Michael wrote:

> On 09.12.02, Michael wrote:
> 
>> I don't understand why I can't catch the error message with my
>> original coding above either.
> 
> The catching of the error message, I should have known:
> response="$(ratpoison -c "$item" 2>&1)"
> 
> Now all I need to know is how to get the colon command line to accept
> a false carriage return.

have you thought about quoting this way:

  response=$(ratpoison -c "${item}$'\n'" 2>&1)

or

  response=$(ratpoison -c "${item}
" 2>&1)


or

  CR='
'
  response=$(ratpoison -c "${item}${CR}" 2>&1)

the >>$'\n'<< is bash syntax.  Most bourne shells, I think, don't break
a backtick commands result, they assign all the words together.  Bash
certainly does.


clemens
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.