bug-textutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Unix Utilities CUT (was: cut bug?)


From: Bob Proulx
Subject: Re: Unix Utilities CUT (was: cut bug?)
Date: Sat Nov 9 13:37:27 2002
User-agent: Mutt/1.4i

Please follow up to the list and not to me privately unless it is
personal.  I forwarded your message back to the list and am following
up to it now.  It is a team effort.

Bill Cecchin <address@hidden> [2002-11-07 13:48:03 -0800]:
> 
> There is the crux of my problem.  I used the cut command as you show below,
> on a text file and got the following results.
> 
> C:\bill\bill\data>cut -d ` ` -f 2 test_spaces.txt
> cut: `: No such file or directory

You are apparently using the MS-Windows COMMAND.COM program as your
shell.  I was not expecting that!  I believe under ms-windows you
would need to use only double-quotes such as cut -d " " in order for
the command.com to work with it.  Not sure.  I don't do windows.

> On our  IBM-AIX Unix servers I use the exact same file and basically the
> same command, but get what I need::
> 
> /wcecchin: cut -d ' ' -f2 test_spaces.txt

UNIX and GNU systems use more advanced command shells, which are about
25 years old now (only a little baiting), and have different quoting
syntax.  If you are using MS-Windows then you need to use MS-Windows
syntax.

> So, I figured it must be some kind of 'bug' in the Windows 2000
> version of GNU Utilities.  I do thank you for your response and
> helping me work this out.  Thank you.  SmileS

Nope.  Unlikely to be a bug.  It is a difference in the quoting of
your MS-Windows system command.com command shell that you are using.
You have to use the quoting syntax for your shell.

You might want to look into the Cygwin tools which provide a port of
the GNU Project software to MS-Windows.  There you would get a real
bash shell which in my not so humble opinion would be an improvement.
But note that you are still running MS-Windows even with the Cygwin
tools installed and therefore you can only expect so much.

  http://www.cygwin.com

Bob




reply via email to

[Prev in Thread] Current Thread [Next in Thread]