delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2018/04/30/00:35:41

X-Recipient: archive-cygwin AT delorie DOT com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:reply-to:subject:to:references:from:message-id
:date:mime-version:in-reply-to:content-type
:content-transfer-encoding; q=dns; s=default; b=y07ny/nw2c6UIyul
QejUbKH23aOR/oMqFjnhwQHxtvdtxtI8mQ33sym9hEEAi6XKX0Hm8skARSSXC1vq
lKlyRlLxFG8K0KgGtT42lbQxoRI3ow+E6kmHWmnyYGoKMjrk7bdhE8L98HAu9e92
lQKhB27qpkWDN+w1OYCbyV+fqeU=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:reply-to:subject:to:references:from:message-id
:date:mime-version:in-reply-to:content-type
:content-transfer-encoding; s=default; bh=U2tw0aPvJVUIevDKYMlB2h
qpwpc=; b=At9A+tVOszYz1cEdQrhjS+sRT+mF2t3uK3YyiGY0s/VnO6QOQIivSA
OEQaZ110ndtKLgudgF7HMz4jZOLIemtqZ1v2UVc8E+aWzGGVJIy5w0qg0imt32bS
Jyart1nvZuT1YS0T36lxXbJhRxHVkFlnvAPQBofl8Q9hd01StMKzc=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Authentication-Results: sourceware.org; auth=none
X-Virus-Found: No
X-Spam-SWARE-Status: No, score=-1.8 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_LOW autolearn=no version=3.3.2 spammy=scheduled, brian, Brian, Hx-spam-relays-external:sk:smtp-ou
X-HELO: smtp-out-no.shaw.ca
X-Authority-Analysis: v=2.3 cv=PvS9kTE3 c=1 sm=1 tr=0 a=MVEHjbUiAHxQW0jfcDq5EA==:117 a=MVEHjbUiAHxQW0jfcDq5EA==:17 a=IkcTkHD0fZMA:10 a=0Uk-Y38ZFAizS5i8tdIA:9 a=QEXdDO2ut3YA:10
Reply-To: Brian DOT Inglis AT SystematicSw DOT ab DOT ca
Subject: Re: update batch file
To: cygwin AT cygwin DOT com
References: <CAG2dRtHn0VTEcuTUmDfM=_S_vrUoYFsJ5J+W50B0217-SdG7Bg AT mail DOT gmail DOT com>
From: Brian Inglis <Brian DOT Inglis AT SystematicSw DOT ab DOT ca>
Message-ID: <90e737d0-2b21-e079-64b1-ffe36ffdc525@SystematicSw.ab.ca>
Date: Sun, 29 Apr 2018 22:35:25 -0600
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0
MIME-Version: 1.0
In-Reply-To: <CAG2dRtHn0VTEcuTUmDfM=_S_vrUoYFsJ5J+W50B0217-SdG7Bg@mail.gmail.com>
X-CMAE-Envelope: MS4wfJC+Dxk5wltvhdm9HN9shCP5hX/Xx/0qjyWuwg/p2rI+drlMIqwgCBKc+GoWx3dnLEZi/O7IJ9oB9TgB9unitso5CZarnU3pxTfMmi1kYrgMgp1Aowm1 MtS+CuF6eVNGaFRNZW7LujwYqHOIkmvyP+5qvwGTVjLbUKOacoeytZndj7ORpDXu8phYcIwLrBr60w==
X-IsSubscribed: yes

On 2018-04-29 19:57, Dave Caswell wrote:
> Has anyone created a batch file that stops the cygwin services, runs
> setup to get updates in the background, and then restarts the
> services??
> Doing it manually, I occasionally forget to restart the services and
> things stop working until I remember to start them up  again.

I launch setup semi-unattended using a script that checks no background
processes running, then updates and validates setup, ini, and local university
unofficial public mirror access, before launching setup, shutting down mintty
and Xwin, and launching task scheduler.
I use an elevated scheduled task to shut down Cygwin services on a preshutdown
event (if I got the conditions correct) or when manually run (just before
setup), and a permanent postinstall script zp_zzz_....dash to restart services
after other postinstall scripts.

You could use an elevated scheduled task to wrap everything in a standalone
script, to save you opening an elevated shell just to run the script.

-- 
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada

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

- Raw text -


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