This is the mail archive of the
cygwin@sources.redhat.com
mailing list for the Cygwin project.
Re: Starting Programms in the background
- To: "Cygwin (E-mail)" <cygwin at sourceware dot cygnus dot com>
- Subject: Re: Starting Programms in the background
- From: Barry Buchbinder <BBUCHBINDER at niaid dot nih dot gov>
- Date: Thu, 2 Nov 2000 09:42:43 -0500
Corinna Vinschen wrote
>klaus.berndl@sdm.de wrote:
>>
>> If i start a program in the background from bash (e.g. "winword.exe
<document> &") then
>> all is working fine. But if i try to exit from the bash-shell from which
i have started the program
>> before i have finished the program then bash writes "logout" but doesn't
terminate until i terminate
>> all previous started programs.
>>
> How can this be avoided, means how to exit bash regardless of any still
running background programs?
>
>Never, I fear. It sounds as if you are running some 9X system. It's
>a problem of all 9X console windows that you can't close the window
>unless all child processes are killed. If you want to run daemons
>invisible you'll have to start them by using a shortcut with the
>minimized state set.
>
>Corinna
>
>--
>Corinna Vinschen Please, send mails regarding Cygwin to
>Cygwin Developer mailto:cygwin@sources.redhat.com
>Red Hat, Inc.
>mailto:vinschen@redhat.com
On my win98 machine, one can start winword from a command.com DOS box and
exit the DOS box before exiting winword. bash behaves as described above,
whether or not "&" is used. However, from bash I can launch winword using
the start command (c:\windows\command\start.exe) and then exit bash. This
is probably because start.exe exits after launching winword. I didn't see a
difference between launching winword.exe and winword.lnk. "&" makes no
difference. One can control how the program opens and whether start exits
immediately.
500 /cygdrive/c> start /?
Runs a Windows program or an MS-DOS program.
START [options] program [arg...]
START [options] document.ext
/m[inimized] Run the new program minimized (in the background).
/max[imized] Run the new program maximized (in the foreground).
/r[estored] Run the new program restored (in the foreground). [default]
/w[ait] Does not return until the other program exits.
501 /cygdrive/c>
Of course you can just start winword the windows way.
- Barry Buchbinder
--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com