This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: Unexpected results: dirs | xargs -n 1 cygpath -aw
- From: Paul <Paul dot Domaskis at gmail dot com>
- To: cygwin at cygwin dot com
- Date: Mon, 30 Sep 2013 18:14:29 +0000 (UTC)
- Subject: Re: Unexpected results: dirs | xargs -n 1 cygpath -aw
- Authentication-results: sourceware.org; auth=none
- References: <loom dot 20130930T180640-573 at post dot gmane dot org> <loom dot 20130930T180840-645 at post dot gmane dot org>
Paul <Paul.Domaskis <at> gmail.com> writes:
> ...if I use xargs with cygpath, it doesn't [give expected results]:
>
> $dirs | xargs -n 1 cygpath -aw
>
> C:\cygwin\home\UserName\projects\project1\~\projects\project1
> C:\cygwin\home\UserName\projects\project1\~\projects\project2
>
> Thanks if anyone can explain what I'm doing wrong.
Kenneth explained that "Tilde (~) is a shell shortcut, but you are
bypassing the shell with $dirs | xargs, so itâs not expected to work". To
avoid the tildes, I successfully used:
$dirs -l | xargs -n 1 cygpath -aw
Thanks, Kenneth!
--
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