X-Recipient: archive-cygwin@delorie.com
X-SWARE-Spam-Status: No, hits=-5.3 required=5.0	tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD
X-Spam-Check-By: sourceware.org
X-IronPortListener: Outbound_SMTP
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: Ar4AAAQWaU6cKEdK/2dsb2JhbABCmG+PE3iBRgEBAQEDEncCAQgNCxwSHxMXAQ0BAQQbGqQrmzCGDWAEhz2EOIxujAI
From: "Buchbinder, Barry (NIH/NIAID) [E]" <BBuchbinder@niaid.nih.gov>
To: "cygwin@cygwin.com" <cygwin@cygwin.com>
Date: Thu, 8 Sep 2011 15:24:08 -0400
Subject: RE: Open Windows Explorer from Cygwin prompt
Message-ID: <0105D5C1E0353146B1B222348B0411A20A23D32229@NIHMLBX02.nih.gov>
References: <4E690DE0.8050204@freesbee.fr> <4E691163.1010309@t-online.de> <4E69139E.5050600@freesbee.fr>
In-Reply-To: <4E69139E.5050600@freesbee.fr>
Content-Type: text/plain; charset="iso-8859-1"
MIME-Version: 1.0
X-IsSubscribed: yes
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com
Content-Transfer-Encoding: 8bit
X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id p88JObk8001831

Vincent Rivière sent the following at Thursday, September 08, 2011 3:13 PM
>Christian Franke wrote:
>>> Cygstart is not needed in this case. Explorer can be launched directly.
>> This works from cmd.exe and from any cygwin shell:
>>
>> explorer .
>
>You are right, this is equivalent in this specific case. But cygstart
>can also open Cygwin-style directories, explorer can't:
>
>cygstart ~
>cygstart /etc
>cygstart dir1/dir2

The following bash script opens Windows Explorer in the directory of the
first argument or the CWD if there are no arguments.

$ cat /usr/local/bin/explore
#!/bin/bash
/bin/cygstart --explore "${1:-.}"

Conversion to an alias is left as an exercise for the reader.

- Barry
  Disclaimer: Statements made herein are not made on behalf of NIAID.



--
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


