bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Unclosed quotes on heredoc mode


From: Robert Elz
Subject: Re: Unclosed quotes on heredoc mode
Date: Wed, 17 Nov 2021 22:33:55 +0700

    Date:        Wed, 17 Nov 2021 12:35:42 +0000
    From:        =?utf-8?Q?Jo=C3=A3o_Almeida_Santos?= 
<j-almeidasantos@hotmail.com>
    Message-ID:  
<VI1PR01MB6896D94B1A6BE026AFBB3340F59A9@VI1PR01MB6896.eurprd01.prod.exchangelabs.com>

  | While testing the heredoc mode, I realized that the $ is not
  | interpreted as variable expansion.

It depends how you set up the heredoc, please give an example of
what you're testing (one which is not doing what you expect, and
indicate exactly what you do expect to happen).

  | But the reason why I'm emailing you is that I whenever I tried to
  | use an unclosed quote on heredoc, it doesn't seem to handle well
  | it never finishes the heredoc.

Again, an example is needed to understand what you're doing.

  | I tried \n for paragraph, verbatim inserting enter,
  | closing quotes on the next line, ... don't know what else to test.

Without seeing what you are actually doing, where the missing quote is
for example (in the heredoc data, or in the word that is after the << ?)
it is hard to suggest anything.

  | I'm on version 5.1 btw.

Show the result of "echo $BASH_VERSION" to provide this info.

  | Is this an expected behavior or a bug?

Impossible to say without more information.   There are several (IMO)
bugs in the way bash processes here documents, whether you're encountering
one of those, something new, or just not understanding the way it is
intended to work is impossible to say with the information you've given.

kre




reply via email to

[Prev in Thread] Current Thread [Next in Thread]