Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com From: ericblake AT comcast DOT net (Eric Blake) To: "Williams, Gerald S (Jerry)" , cygwin AT cygwin DOT com Subject: Re: SETUP: In-use files have been replaced Date: Tue, 18 Oct 2005 19:32:29 +0000 Message-Id: <101820051932.29698.43554DCD0005D0920000740222064246130A050E040D0C079D0A@comcast.net> > I use this handy little script on my machine to help me stop > (and restart) all services: It would help if I didn't paste it wrong (I was using a nested case in my version, to special case one of my own services that is not a cygwin standard, and didn't completely strip the nested case before posting): > > $ cat serv > #!/bin/bash > usage='serv: manage cygwin services during cygwin upgrades > usage: serv {--help|--stop|--start}' > > case $# in > 1) case $1 in > --help|-h) echo "$usage"; exit 0 ;; > --stop) for service in `cygrunsrv --list` inetd ; do > echo "stopping $service" > cygrunsrv --stop $service || echo "problems with $service" ;; There should not be a ;; on this line. > done ;; > --start) for service in `cygrunsrv --list` inetd ; do > echo "starting $service" > cygrunsrv --start $service || echo "problems with $service" > done ;; > esac ;; > *) echo "$usage"; exit 1 ;; > esac > -- Eric Blake -- 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/