This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: drag and drop folder from Explorer to cygwin


Richard Trevor wrote:

> I'd like to drag a folder from Windows Explorer (XP) and drop it on the cygwin desktop shortcut,
> causing a cygwin (bash) shell to open in the folder directory.

I don't think there's any magic to it, when you drop something onto a
shortcut it just sets the arguments to the filenames of the items.  So
you'd need to modify the batch file to check if %1 is set and use the
chere mechanism, i.e. cd to %1 and then set CHERE_INVOKING to prevent
the /etc/profile from changing to $HOME.

Brian

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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]