<feed xmlns='http://www.w3.org/2005/Atom'>
<title>busybox-w32/testsuite/cut.tests, branch long_paths</title>
<subtitle>A mirror of https://github.com/rmyorston/busybox-w32.git
</subtitle>
<id>https://git.lua4.win/busybox-w32/atom?h=long_paths</id>
<link rel='self' href='https://git.lua4.win/busybox-w32/atom?h=long_paths'/>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/'/>
<updated>2024-12-20T21:12:33+00:00</updated>
<entry>
<title>cut: fix up -D/-s behavior with -F</title>
<updated>2024-12-20T21:12:33+00:00</updated>
<author>
<name>Denys Vlasenko</name>
<email>vda.linux@googlemail.com</email>
</author>
<published>2024-12-20T21:12:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=b03f5162ac239c3743cfac246b3760b0020f4d23'/>
<id>urn:sha1:b03f5162ac239c3743cfac246b3760b0020f4d23</id>
<content type='text'>
function                                             old     new   delta
cut_main                                            1388    1402     +14
packed_usage                                       34934   34933      -1
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 1/1 up/down: 14/-1)              Total: 13 bytes

Signed-off-by: Denys Vlasenko &lt;vda.linux@googlemail.com&gt;
</content>
</entry>
<entry>
<title>cut: fix -F n-m to match toybox</title>
<updated>2024-12-14T12:58:49+00:00</updated>
<author>
<name>Denys Vlasenko</name>
<email>vda.linux@googlemail.com</email>
</author>
<published>2024-12-14T12:58:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=b25ea3f156c6b5927b358f9b12b90f1852f30311'/>
<id>urn:sha1:b25ea3f156c6b5927b358f9b12b90f1852f30311</id>
<content type='text'>
function                                             old     new   delta
cut_main                                            1339    1391     +52

Signed-off-by: Denys Vlasenko &lt;vda.linux@googlemail.com&gt;
</content>
</entry>
<entry>
<title>cut: fix handling of -d ''</title>
<updated>2024-12-13T18:31:41+00:00</updated>
<author>
<name>Denys Vlasenko</name>
<email>vda.linux@googlemail.com</email>
</author>
<published>2024-12-13T18:31:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=96a230f17ba6cb1a7ad1e383d595424da02e87fc'/>
<id>urn:sha1:96a230f17ba6cb1a7ad1e383d595424da02e87fc</id>
<content type='text'>
Signed-off-by: Denys Vlasenko &lt;vda.linux@googlemail.com&gt;
</content>
</entry>
<entry>
<title>cut: fix -d$'\n' --output-delimiter=@@ behavior</title>
<updated>2024-12-10T20:01:52+00:00</updated>
<author>
<name>Denys Vlasenko</name>
<email>vda.linux@googlemail.com</email>
</author>
<published>2024-12-10T20:01:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=9e364b16d1020cb7b8f8f4d4f3fe1833496b7a12'/>
<id>urn:sha1:9e364b16d1020cb7b8f8f4d4f3fe1833496b7a12</id>
<content type='text'>
function                                             old     new   delta
cut_main                                            1261    1353     +92
packed_usage                                       34925   34901     -24
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 1/1 up/down: 92/-24)             Total: 68 bytes

Signed-off-by: Denys Vlasenko &lt;vda.linux@googlemail.com&gt;
</content>
</entry>
<entry>
<title>cut: implement --output-delimiter</title>
<updated>2024-12-10T17:49:10+00:00</updated>
<author>
<name>Denys Vlasenko</name>
<email>vda.linux@googlemail.com</email>
</author>
<published>2024-12-10T17:49:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=a208fa03de8467d1f51821f874cbf142aaad74fa'/>
<id>urn:sha1:a208fa03de8467d1f51821f874cbf142aaad74fa</id>
<content type='text'>
function                                             old     new   delta
cut_main                                            1204    1261     +57
static.cut_longopts                                    -      20     +20
------------------------------------------------------------------------------
(add/remove: 1/0 grow/shrink: 1/0 up/down: 77/0)               Total: 77 bytes

Signed-off-by: Denys Vlasenko &lt;vda.linux@googlemail.com&gt;
</content>
</entry>
<entry>
<title>cut: fix "echo 1.2 | cut -d. -f1,3" (print "1", not "1.")</title>
<updated>2024-12-10T16:21:30+00:00</updated>
<author>
<name>Denys Vlasenko</name>
<email>vda.linux@googlemail.com</email>
</author>
<published>2024-12-10T16:21:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=103139d0e6e97c188a647adeb5c71eb39c308c26'/>
<id>urn:sha1:103139d0e6e97c188a647adeb5c71eb39c308c26</id>
<content type='text'>
function                                             old     new   delta
cut_main                                            1228    1201     -27

Signed-off-by: Denys Vlasenko &lt;vda.linux@googlemail.com&gt;
</content>
</entry>
<entry>
<title>cut: improve detection of invalid ranges</title>
<updated>2024-12-10T00:29:44+00:00</updated>
<author>
<name>Ron Yorston</name>
<email>rmy@pobox.com</email>
</author>
<published>2024-11-03T12:47:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=f02041441344389b05d10fe6ba8759b6670b8e10'/>
<id>urn:sha1:f02041441344389b05d10fe6ba8759b6670b8e10</id>
<content type='text'>
Commit 0068ce2fa (cut: add toybox-compatible options -O OUTSEP,
-D, -F LIST) added detection of reversed ranges.  Further
improvements are possible.

- The test for reversed ranges compared the start after it had been
  decremented with the end before decrement.  It thus missed ranges
  of the form 2-1.

- Zero isn't a valid start value for a range.  (Nor is it a valid
  end value, but that's caught by the test for a reversed range.)

- The code

        if (!*ltok)
            e = INT_MAX;

  duplicates a check that's already been made.

- Display the actual range in the error message to make it easier
  to find which range was at fault.

function                                             old     new   delta
.rodata                                           100273  100287     +14
cut_main                                            1239    1237      -2
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 1/1 up/down: 14/-2)              Total: 12 bytes

Signed-off-by: Ron Yorston &lt;rmy@pobox.com&gt;
Signed-off-by: Denys Vlasenko &lt;vda.linux@googlemail.com&gt;
</content>
</entry>
<entry>
<title>cut: fix "-s" flag to omit blank lines</title>
<updated>2024-12-10T00:27:04+00:00</updated>
<author>
<name>Colin McAllister</name>
<email>colinmca242@gmail.com</email>
</author>
<published>2024-07-17T21:33:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=50e2b59370542097eb0efd79cc8d3d39ee52bf82'/>
<id>urn:sha1:50e2b59370542097eb0efd79cc8d3d39ee52bf82</id>
<content type='text'>
Using cut with the delimiter flag ("-d") with the "-s" flag to only
output lines containing the delimiter will print blank lines. This is
deviant behavior from cut provided by GNU Coreutils. Blank lines should
be omitted if "-s" is used with "-d".

This change introduces a somewhat naiive, yet efficient solution, where
line length is checked before looping though bytes. If line length is
zero and the "-s" flag is used, the code will jump to parsing the next
line to avoid printing a newline character.

function                                             old     new   delta
cut_main                                            1196    1185     -11

Signed-off-by: Colin McAllister &lt;colinmca242@gmail.com&gt;
Signed-off-by: Denys Vlasenko &lt;vda.linux@googlemail.com&gt;
</content>
</entry>
<entry>
<title>cut: fix testsuite</title>
<updated>2021-08-15T18:15:42+00:00</updated>
<author>
<name>Denys Vlasenko</name>
<email>vda.linux@googlemail.com</email>
</author>
<published>2021-08-15T18:15:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=eaa8ee40aa049040e9f9bb1d967754102742c227'/>
<id>urn:sha1:eaa8ee40aa049040e9f9bb1d967754102742c227</id>
<content type='text'>
Signed-off-by: Denys Vlasenko &lt;vda.linux@googlemail.com&gt;
</content>
</entry>
<entry>
<title>cut: add toybox-compatible options -O OUTSEP, -D, -F LIST</title>
<updated>2021-07-20T14:29:22+00:00</updated>
<author>
<name>Rob Landley</name>
<email>rob@landley.net</email>
</author>
<published>2021-07-20T14:02:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=0068ce2fa0e3dbc618b8ca87ab56e144731da784'/>
<id>urn:sha1:0068ce2fa0e3dbc618b8ca87ab56e144731da784</id>
<content type='text'>
function                                             old     new   delta
cut_main                                             884    1201    +317
packed_usage                                       33823   33885     +62
.rodata                                           104186  104179      -7
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 2/1 up/down: 379/-7)            Total: 372 bytes

Signed-off-by: Rob Landley &lt;rob@landley.net&gt;
Signed-off-by: Denys Vlasenko &lt;vda.linux@googlemail.com&gt;
</content>
</entry>
</feed>
