delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2004/03/13/15:25:32

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
Reply-To: Cygwin List <cygwin AT cygwin DOT com>
Message-Id: <6.0.1.1.0.20040313152200.03a2db60@127.0.0.1>
X-Sender:
Date: Sat, 13 Mar 2004 15:22:59 -0500
To: zzapper <david AT tvis DOT co DOT uk>, cygwin AT cygwin DOT com
From: Larry Hall <cygwin-lh AT cygwin DOT com>
Subject: Re: Converting Dos Slashes to Unix Slashes
In-Reply-To: <vvo6501upvrqpv62er6nv75ton1k3p0j7h@4ax.com>
References: <vvo6501upvrqpv62er6nv75ton1k3p0j7h AT 4ax DOT com>
Mime-Version: 1.0

At 03:10 PM 3/13/2004, you wrote:
>hi,
>I thought I'd write a simple script to allow me to cd to a DOS path
>that I had in my paste buffer, turned out to be tricky
>
>alias doscd='. doscd'
>#!bash
># doscd
># description : convert dos paths
>result=$(echo $1 | sed "s/\\\/\//g")
>\cd $result
>
>
>> doscd "c:\temp\fred"
>
>That more or less works but I have to quote the "Dos path" and it
>freaks out if a directory begins with a
>
>eg
>> doscd "c:\aaa\"
>Cannot find c:/aa/
>
>Cygpath hardly helps because I'd need to backslash (no gain)
>
>cygpath --unix C:\\cygwin\\bin\\cygwin.bat
>
>Any ideas?1?
>
>zzapper (vim & cygwin & zsh)
>--
>
>vim -c ":%s/^/WhfgTNabgureRIvzSUnpxre/|:%s/[R-T]/ /Ig|:normal ggVGg?"


How about:

cygpath --unix "C:\cygwin\bin\cygwin.bat"

?

--
Larry Hall                              http://www.rfk.com
RFK Partners, Inc.                      (508) 893-9779 - RFK Office
838 Washington Street                   (508) 893-9889 - FAX
Holliston, MA 01746                     


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

- Raw text -


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