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 To: cygwin AT cygwin DOT com From: zzapper Subject: Re: launch windows program from shell according to its extension Date: Wed, 08 Jun 2005 15:46:34 +0100 Lines: 37 Message-ID: References: <6 DOT 2 DOT 1 DOT 2 DOT 0 DOT 20050608092313 DOT 07166ac8 AT pop DOT prospeed DOT net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-IsSubscribed: yes On Wed, 08 Jun 2005 09:23:53 -0400, wrote: >At 03:45 AM 6/8/2005, you wrote: >>Hello, >> >>I have largely replaced usage of windows explorer with a cygwin shell. One thing >>is cumbersome however: when I encounter, say, a .doc file in a directory, it >>would be nice that I could "launch" this file with the program associated under >>windows. >> >>Is this possible, for example via a utility program kind of "launch file.doc"? > > >Sure. Use 'cygstart'. script to launch most recent file #!/bin/bash # csn # description : launch most recent file (head) # set -x cygstart $(l\s -t * | head -1) & Jump back into explorer in CURRENT directory wexp () { XPATH="$(cygpath -w "${PWD}")" explorer $XPATH } man cygstart man cygpath -- zzapper vim -c ":%s%s*%Cyrnfr)fcbafbe[Oenz(Zbbyranne%|:%s)[[()])-)Ig|norm Vg?" http://www.rayninfo.co.uk/tips/ vim, zsh & success tips -- 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/