Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sources DOT redhat DOT com Delivered-To: mailing list cygwin AT sources DOT redhat DOT com Message-ID: From: klaus DOT berndl AT sdm DOT de To: cygwin AT sourceware DOT cygnus DOT com Subject: AW: Ultimative way to start Windows 95/98/NT/2000 programs from b ash Date: Sat, 11 Nov 2000 09:21:02 +0100 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2650.21) Content-Type: text/plain; charset="iso-8859-1" Ok, here comes a more ultimative way :-) A slightly enhancement to my previous function: # open any file in the correct program: a registered file-type (see assoc # and ftype at W32) will be opened with the associated program. If this # fails (maybe because the filetype is not registered) the file will be # opened with the texteditor (here Emacs). function open-file-with-w32 () { for i in $*; do cmd /c /q start /b `cygpath -w "$i"` 2>/dev/null || e `cygpath -w "$i"` done; } alias o=open-file-with-w32 Only replace the 'e' in this function with your text-editor-command (for me 'e' starts Emacs). Now you can open *all* filetypes simply with 'o' regardless if they are associated with a program in Windows NT. Klaus -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com