Subject: Old favourite: Terminate batch job (Y/N)?
From: "fergus" <[email-masked]>
To: <[email-masked]>
Cc: <[email-masked]>
Date: Mon, 30 Oct 2006 11:57:55 -0000

For compelling reasons I start bash through a .cmd file with contents

	{commandlist 1}
	{sequence of "mount" instuctions}
	:: next line is to confirm that these instructions have been
implemented
	mount
	bash
	{commandlist 2}

If during the bash session I issue ctrl-C to interrupt something, then on
exiting bash the ctrl-C instruction seems to have been queued for use and I
am invited to "Terminate batch job (Y/N)?" before commencing the sequence at
{commandlist 2}.

This is an old problem and there are various solutions offered in the
archives to prevent the presentation of this annoying invitation, of which
the most useful seems to be to preface the bash command with "start": ie.
amend one line in the .cmd file so that it reads

	{commandlist 1}
	{sequence of "mount" instructions}
	:: next line is to confirm that these instructions have been
implemented
	mount
	start bash
	{commandlist 2}

However, I find that if I do this, then on starting bash, all the
instructions issued in the preceding {sequence of "mount" intructions} are
ignored in the new bash process. (But they were carried out correctly, as
was confirmed; and the consequences of the instructions issued in
{commandlist 1} are remembered. So it's not that all the contents of the
.cmd file preceding the start bash command are, for whatever reason,
ignored. Just some of them!)

Can anybody explain what's going on here? And can anybody offer a mechanism
for suppressing the "Terminate batch job? (Y/N)" invitation that is less
prone to breaking something else?

Thank you.

Fergus

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