Commit graph

6815 commits

Author SHA1 Message Date
Jeffrey Finkelstein
ec3bcf4067 util: replace all instances of printf
Add the `g` flag to one of the regular expression substitutions in
`util/build-gnu.sh` so that all instances of `printf` are replaced
with `/usr/bin/printf` in `tests/dd/ascii.sh` instead of just one
instance per line.
2022-01-23 09:52:25 -05:00
Cecylia Bocovich
c8f9ea5b15
tests/join: test default check order behaviour 2022-01-22 17:51:29 -05:00
Cecylia Bocovich
594157d1e0
join: fix default check order behaviour
If neither --nocheck-order or --check-order are specified, only fail on
unsorted inputs if either file contains unpaired lines.
2022-01-22 17:51:29 -05:00
Terts Diepraam
7014607f0a Merge branch 'main' into mdbook 2022-01-22 12:42:19 +01:00
Terts Diepraam
a575932115 uudoc: fix clippy lint 2022-01-22 11:59:41 +01:00
Terts Diepraam
d896ccfd90 docs: fix links in introduction 2022-01-22 11:51:41 +01:00
Terts Diepraam
a3ca29b612 docs: create SUMMARY.md automatically 2022-01-22 11:49:33 +01:00
Sylvestre Ledru
8a787fe028
Merge pull request #2904 from jfinkels/tail-lines-positive-number-file
tail: fix a bug in tail [ -n | -c ] +NUM <file>
2022-01-22 10:18:38 +01:00
Jeffrey Finkelstein
bfc0d81481 ci: update default branch to "main" in workflows 2022-01-21 23:07:16 -05:00
Jeffrey Finkelstein
f595edaded tail: fix a bug in tail [ -n | -c ] +NUM <file>
Fix a bug when getting all but the first NUM lines or bytes of a file
via `tail -n +NUM <file>` or `tail -c +NUM <file>`. The bug only
existed when a file is given as an argument; it did not exist when the
input data came from stdin.
2022-01-21 19:05:53 -05:00
Jeffrey Finkelstein
d27d6bc32c split: add forwards_thru_file() helper function
Add helper function `forwards_thru_file()` that finds the index in a
reader of the byte immediately following the `n`th instance of a given
byte.
2022-01-21 18:33:15 -05:00
Jeffrey Finkelstein
58d84d5107 tail: support zero-terminated lines in streams
Support `-z` option when the input is not a seekable file. Previously,
the option was accepted by the argument parser, but it was being
ignored by the application logic.
2022-01-21 18:31:15 -05:00
Terts Diepraam
b2c7177106 docs: get installation instructions directly from README.md 2022-01-21 23:24:10 +01:00
Sylvestre Ledru
8c298e97a5
expr: Fix a warning in the doc generation (#2900)
```
warning: this URL is not a hyperlink
```
2022-01-21 23:14:05 +01:00
Sylvestre Ledru
c4a74c2231
Fix doc warnings in entries.rs (#2901) 2022-01-21 23:13:54 +01:00
Justin Tracey
b65815cd06 ls: fix clippy lints in tests 2022-01-21 15:56:42 -05:00
Terts Diepraam
9618a2f21d docs: remove custom files 2022-01-21 20:18:36 +01:00
Terts Diepraam
8c53854aca
Merge pull request #2899 from cohosh/join_chkodr_error_fix
join: print unsorted line in error message
2022-01-21 19:45:29 +01:00
Terts Diepraam
e3558ff3a8 docs: additional spelling fixes 2022-01-21 19:43:40 +01:00
Terts Diepraam
ab3623f65a docs: usage and values for options 2022-01-21 19:20:55 +01:00
Terts Diepraam
274459f2ed docs: spelling fixes 2022-01-21 18:28:51 +01:00
Cecylia Bocovich
67878de379
join: print unsorted line in error message
This expands the error message that is printed if either input file has
an unsorted line. Both the program name (join) and the offending line
are printed out with the message to match the behaviour of the GNU
utility.
2022-01-21 11:47:37 -05:00
Terts Diepraam
9ddd61ab6b Merge branch 'main' into hbina-tr-reimplement-expansion 2022-01-21 14:42:30 +01:00
Terts Diepraam
bd4d26d37c docs: remove old manpage generation 2022-01-20 23:30:01 +01:00
Terts Diepraam
83d5d1558e docs: add multi-call binary 2022-01-20 23:30:01 +01:00
Terts Diepraam
5ff4796b12 docs: add version 2022-01-20 23:20:29 +01:00
Terts Diepraam
55a47f6fc0
Merge pull request #2863 from tertsdiepraam/clap-3
Clap 3
2022-01-20 23:14:52 +01:00
Sylvestre Ledru
d64b32d121
Merge pull request #2885 from jfinkels/head-find-nth-line-from-end
head: refactor helper function find_nth_line_from_end()
2022-01-20 21:53:47 +01:00
Sylvestre Ledru
0c34e35fdb
Merge pull request #2896 from tertsdiepraam/flaky-tr-test
`tr`: fix flaky test
2022-01-20 21:53:27 +01:00
electricboogie
0b53cd8c4a Make suggested changes 2022-01-20 14:52:45 -06:00
Terts Diepraam
a903fee569 docs: favicon, installation instructions, better introduction page 2022-01-20 21:02:44 +01:00
Terts Diepraam
68c584fef6 docs: adjust space for options 2022-01-20 18:41:07 +01:00
Terts Diepraam
cf42008150 autogenerated mdbook documentation 2022-01-20 16:49:44 +01:00
Terts Diepraam
951035e49c mdbook docs 2022-01-20 15:00:36 +01:00
Terts Diepraam
9f649ffe9b tr: fix flaky test 2022-01-19 22:33:54 +01:00
Terts Diepraam
b51a6e8fe3 tr: make parsing of sets more terse 2022-01-19 21:03:57 +01:00
Terts Diepraam
da728dd2b6 Merge branch 'main' into hbina-tr-reimplement-expansion 2022-01-19 19:34:13 +01:00
Terts Diepraam
6aa433c70a tr: adapt copyright to new guidelines 2022-01-19 19:07:17 +01:00
Roy Ivy III
2e251f91f1 0.0.12 2022-01-19 05:35:00 -06:00
Sylvestre Ledru
b45351f40f
Merge pull request #2887 from jfinkels/tail-no-trailing-newline
tail: don't add trailing \n if input doesn't end with one
2022-01-19 09:29:24 +01:00
Jeffrey Finkelstein
ca812a7558 tail: rm trailing \n if input doesn't end with one
Fix a bug where `tail` would inappropriately add a newline to the last
line of output even though the input did not end with one.
2022-01-18 17:34:41 -05:00
Terts Diepraam
4b79419514 runcon/hashsum: remove references to get_matches_from_safe 2022-01-18 16:34:06 +01:00
Terts Diepraam
77229aea86 ls: fix tests for windows 2022-01-18 13:47:50 +01:00
Terts Diepraam
0a30c43bb6 chcon: use try_get_matches_from 2022-01-18 13:06:02 +01:00
Terts Diepraam
e345768484 base64: remove clap dependency again 2022-01-18 12:56:58 +01:00
Terts Diepraam
270a6ee83e rm: fix 3 leading hyphens for ---presume-input-tty 2022-01-18 12:54:50 +01:00
Sylvestre Ledru
13de6cabfc
Merge pull request #2886 from jfinkels/tail-io-error
tail: improve error handling when file not found
2022-01-18 09:21:57 +01:00
Justin Tracey
ce3df12eaa join: "support" field numbers larger than usize::MAX
They silently get folded to usize::MAX, which is the official GNU behavior.
2022-01-17 17:49:41 -05:00
electricboogie
4bee6526bf Add new test, never print error on deref-ed bad fd 2022-01-17 13:14:43 -06:00
Jeffrey Finkelstein
e575007629 tail: improve error handling when file not found 2022-01-17 10:57:24 -05:00