Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 21 Jan 2021 22:18:55 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 252896] usr.bin/cut when used with -w will replace first delimiter with \t delimter
Message-ID:  <bug-252896-227@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D252896

            Bug ID: 252896
           Summary: usr.bin/cut when used with -w will replace first
                    delimiter with \t delimter
           Product: Base System
           Version: 12.1-RELEASE
          Hardware: amd64
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: bin
          Assignee: bugs@FreeBSD.org
          Reporter: antispam007@mac.com

It seems that cut is replacing Space Char with a Tab Char when you use the
special function -w for delimiters

Fast proof could be a=20
     ls -al | cut -w -f x- (where x the field number)
you will get someting like
     filed-x <TAB> field-x+1 <SPC> field-x+2 <SPC> ...
instead of=20
     filed-x <SPC> field-x+1 <SPC> field-x+2 <SPC> ...

You could verify it with hd(1) where you see 09 for <TAB> and <20> for SPC

Expected behaviour would be, that cut is not touching/changing the field
delimiter

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-252896-227>