delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2004/02/29/21:11:40

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/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
Message-ID: <40429BC9.9000409@sbcglobal.net>
Date: Sun, 29 Feb 2004 20:11:21 -0600
From: Gregory Borota <cygwin AT sbcglobal DOT net>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.6) Gecko/20040113
MIME-Version: 1.0
To: Cygwin List <cygwin AT cygwin DOT com>
Subject: Cygwin Shell Here
X-IsSubscribed: yes

--------------080301050704000509050109
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit

In Windows Explorer I want to add a "CYGWIN Shell" context menu option 
on file system folders, giving me a quick way to open a Cygwin window 
pointing at the selected folder. This is what I came up with:

1. In the cygwin.bat file I add the line

set __CYG_PATH_=%~1

(somewhere before 'bash --login -i' line)


2. In my .bash_profile I add the line:

cd "$__CYG_PATH_"


3. I add to the registry the following lines:

[HKEY_CLASSES_ROOT\Directory\shell\CygCmd]
@="CYGWIN Shell"

[HKEY_CLASSES_ROOT\Directory\shell\CygCmd\command]
@="C:\\cygwin\\cygwin.bat \"%1\""

[HKEY_CLASSES_ROOT\Drive\shell\CygCmd]
@="CYGWIN Shell"

[HKEY_CLASSES_ROOT\Drive\shell\CygCmd\command]
@="C:\\cygwin\\cygwin.bat \"%1\""


I wonder if there isn't a simpler and nicer way to do this?

Gregory

--------------080301050704000509050109
Content-Type: text/plain;
 name="Cygwin.reg.txt"
Content-Transfer-Encoding: base64
Content-Disposition: inline;
 filename="Cygwin.reg.txt"

//5XAGkAbgBkAG8AdwBzACAAUgBlAGcAaQBzAHQAcgB5ACAARQBkAGkAdABv
AHIAIABWAGUAcgBzAGkAbwBuACAANQAuADAAMAANAAoADQAKAFsASABLAEUA
WQBfAEMATABBAFMAUwBFAFMAXwBSAE8ATwBUAFwARABpAHIAZQBjAHQAbwBy
AHkAXABzAGgAZQBsAGwAXABDAHkAZwBDAG0AZABdAA0ACgBAAD0AIgBDAFkA
RwBXAEkATgAgAFMAaABlAGwAbAAiAA0ACgANAAoAWwBIAEsARQBZAF8AQwBM
AEEAUwBTAEUAUwBfAFIATwBPAFQAXABEAGkAcgBlAGMAdABvAHIAeQBcAHMA
aABlAGwAbABcAEMAeQBnAEMAbQBkAFwAYwBvAG0AbQBhAG4AZABdAA0ACgBA
AD0AIgBDADoAXABcAGMAeQBnAHcAaQBuAFwAXABjAHkAZwB3AGkAbgAuAGIA
YQB0ACAAXAAiACUAMQBcACIAIgANAAoADQAKAFsASABLAEUAWQBfAEMATABB
AFMAUwBFAFMAXwBSAE8ATwBUAFwARAByAGkAdgBlAFwAcwBoAGUAbABsAFwA
QwB5AGcAQwBtAGQAXQANAAoAQAA9ACIAQwBZAEcAVwBJAE4AIABTAGgAZQBs
AGwAIgANAAoADQAKAFsASABLAEUAWQBfAEMATABBAFMAUwBFAFMAXwBSAE8A
TwBUAFwARAByAGkAdgBlAFwAcwBoAGUAbABsAFwAQwB5AGcAQwBtAGQAXABj
AG8AbQBtAGEAbgBkAF0ADQAKAEAAPQAiAEMAOgBcAFwAYwB5AGcAdwBpAG4A
XABcAGMAeQBnAHcAaQBuAC4AYgBhAHQAIABcACIAJQAxAFwAIgAiAA0ACgA=


--------------080301050704000509050109
Content-Type: text/plain; charset=us-ascii

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

- Raw text -


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