delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2020/07/27/12:52:36

X-Recipient: archive-cygwin AT delorie DOT com
X-Original-To: cygwin AT cygwin DOT com
Delivered-To: cygwin AT cygwin DOT com
DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 9F3553857C65
Authentication-Results: sourceware.org;
dmarc=none (p=none dis=none) header.from=cs.umass.edu
Authentication-Results: sourceware.org;
spf=pass smtp.mailfrom=moss AT cs DOT umass DOT edu
Subject: Re: Problem with output from gawk software in recent Cygwin
installation
To: Bryan VanSchouwen <vanschbm2 AT gmail DOT com>, cygwin AT cygwin DOT com
References: <CAC7Qdh1bPAejJZkV6GY96kcAVKNFDvGcTBpbSfXY6jC-aMGsiQ AT mail DOT gmail DOT com>
From: Eliot Moss <moss AT cs DOT umass DOT edu>
Message-ID: <1729e34a-245c-2e87-6604-bebf8e08d62b@cs.umass.edu>
Date: Mon, 27 Jul 2020 12:51:43 -0400
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101
Thunderbird/68.10.0
MIME-Version: 1.0
In-Reply-To: <CAC7Qdh1bPAejJZkV6GY96kcAVKNFDvGcTBpbSfXY6jC-aMGsiQ@mail.gmail.com>
X-Spam-Status: No, score=-2.3 required=5.0 tests=BAYES_00, JMQ_SPF_NEUTRAL,
KAM_DMARC_STATUS, SPF_HELO_NONE, SPF_PASS,
TXREP autolearn=no autolearn_force=no version=3.4.2
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on
server2.sourceware.org
X-BeenThere: cygwin AT cygwin DOT com
X-Mailman-Version: 2.1.29
List-Id: General Cygwin discussions and problem reports <cygwin.cygwin.com>
List-Unsubscribe: <http://cygwin.com/mailman/options/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=unsubscribe>
List-Archive: <https://cygwin.com/pipermail/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-request AT cygwin DOT com?subject=help>
List-Subscribe: <http://cygwin.com/mailman/listinfo/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=subscribe>
Reply-To: moss AT cs DOT umass DOT edu
Errors-To: cygwin-bounces AT cygwin DOT com
Sender: "Cygwin" <cygwin-bounces AT cygwin DOT com>

On 7/27/2020 11:47 AM, Bryan VanSchouwen via Cygwin wrote:
> Hello.
> 
> I just tried executing an awk script using the most recent version of gawk,
> but the output did not turn out the way that it was supposed to.
> 
> This script uses the following command to print the output data to the
> output file:
> print(cai[i], rpi[i], i) >
> "Fit_Height_correln_plot_-_cPuMP_vs_2NH2-cPuMP.dat"
> 
> and previously, this command always printed the values of the three
> variables on a single line, separated by spaces; however, now the gawk
> software is automatically adding hard-returns between the values, resulting
> in the three values being printed on separate lines within the data file.
> 
> What is going on here, and how do I permanently make it stop??

Here's a wondering: Could it have to do with line endings?  If Windows
CRLF is getting in there, then the variables might get a CR in them,
which might do weird things.  This assumes those are string variables,
not numeric.

Best - EM
--
Problem reports:      https://cygwin.com/problems.html
FAQ:                  https://cygwin.com/faq/
Documentation:        https://cygwin.com/docs.html
Unsubscribe info:     https://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019