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 Date: Thu, 28 Jul 2005 09:38:35 -0400 (EDT) From: Igor Pechtchanski Reply-To: cygwin AT cygwin DOT com To: Ken Dibble cc: cygwin AT cygwin DOT com Subject: Re: suggestions for cygwin developers In-Reply-To: <42E8B7CA.6080602@alltel.net> Message-ID: References: <9bbd279405072717252b3e0690 AT mail DOT gmail DOT com> <42E8A1DA DOT 20605 AT atomice DOT net> <42E8B7CA DOT 6080602 AT alltel DOT net> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On Thu, 28 Jul 2005, Ken Dibble wrote: > Chris January wrote: > > > Alex Goldman wrote: > > > > > When Cygwin gets set up, it would be more user-friendly if it placed > > > two icons on the desktop: > > > one should start maximized Rxvt; another should start X with a > > > couple of xterms or whatever. > > > First-time users might think that the MS-DOS terminal is as good as > > > it gets, and this is not good for Cygwin. Others still have to > > > figure out how to start Rxvt automatically and how to configure it > > > to look pretty. > > > > > > Also, it would be neat to be able to keep Cygwin up-to-date > > > automatically. > > > > How about a prompt when a new Cygwin DLL version is available: > > > > A new version of Cygwin is available. Run setup to install the latest > > version. > > > > This could be included as part of the /etc/profile or something. > > > > Chris > > Checking to see if a new version available assumes an internet > connection. My opinion is that this would play havoc with dial-up users. Agreed. I would guess it could be a small service (a nice implementation would even put an icon in the system tray). > If this is something you want, here is a hack to accomplish it. > I'm sure there are better, cleaner ways to do this and it will break > as soon as something in the package list changes, but it's 5 am > and I am not ready to think yet. While the effort of actually writing code at 5am is commendable (especially since you said "yet" -- the only time you'd see *me* writing code at 5am is if I'd been doing it all night :-) ), the code below does do some wasteful things. > #!/bin/bash > > #Igor's whichpkg > function whichpkg() { > wget -qO- "http://cygwin.com/cgi-bin2/package-grep.cgi?grep=$1" | \ > sed -ne '/Cygwin Package List/,${s###g;p}' > } You could also simply 'wget -qO- "http://cygwin.com/packages/cygwin"' and find the last line that starts with "cygwin". That would be *wa-ay* faster. > LATEST=`whichpkg cygwin | grep "emulation" | tail -1 | awk -F "-" '{print $2}'` Even if you do use the "whichpkg" above, it's probably better to search for 'cygwin1\.dll'... :-) Besides, this would lose the Cygwin-specific release number. > CUR=`uname -a | awk '{print $3}' | awk -F"(" '{print $1}'` CUR=`uname -r | awk -F"(" '{print $1}'` or CUR=`cygcheck -cd cygwin | sed -ne 's/^cygwin\s\+// p'` Both will not do the right thing if you have a snapshot installed. You'll have to think about what exactly the "right thing" is in this case. > if [ $CUR != $LATEST ]; then > echo "new cygwin dll version "$LATEST" available" > else > echo "Your cygwin dll is current" > fi Again, you need to also deal with snapshots. But if this were written in C, run as a service, and extended to all installed packages, it could be the beginning of something useful. :-) Igor -- http://cs.nyu.edu/~pechtcha/ |\ _,,,---,,_ pechtcha AT cs DOT nyu DOT edu ZZZzz /,`.-'`' -. ;-;;,_ igor AT watson DOT ibm DOT com |,4- ) )-,_. ,\ ( `'-' Igor Pechtchanski, Ph.D. '---''(_/--' `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-. Meow! If there's any real truth it's that the entire multidimensional infinity of the Universe is almost certainly being run by a bunch of maniacs. /DA -- 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/