Sylvestre Ledru
34ecff82f9
Merge pull request #2343 from flip1995/cleanup-readme
...
README: Cleanup utility list
2021-06-04 19:50:48 +02:00
Michael Debertol
e7fa6715a7
Merge branch 'master' of https://github.com/uutils/coreutils into ln/dst-symlink
2021-06-04 19:42:19 +02:00
Sylvestre Ledru
96f16f6a57
Merge pull request #2341 from sylvestre/more-gnu
...
Improve GNU testsuite + improve rm output
2021-06-04 18:22:34 +02:00
Jan Scheer
81e07a6a4d
od: replace 'piped_stdin' to make test stable
2021-06-04 17:22:45 +02:00
flip1995
b7061d1817
README: Cleanup utility list
...
In PR #2300 an old commit got merged putting back utilities that were
already implemented into "To Do". This commit reverts this. In addition
it moves `numfmt` to Semi-Done and sorts the Semi-Done column
alphabetically.
This should now be the up-to-date list of utilities. There are 96
utilities in Done or Semi-Done and `ls -1 src/uu | wc -l` also outputs
96.
2021-06-04 16:29:32 +02:00
Dean Li
acd290d11f
more: fix unicode bug for breakline
...
- Use `unicode_segmentation` and `unicode_width` to determine proper `break_line` position.
- Keep track of total_width as suggested by @tertsdiepraam.
- Add unittest for ZWJ unicode case
Related to #2319 .
2021-06-04 22:06:27 +08:00
Jan Scheer
f8e96150f8
fix clippy warnings and spelling
...
* add some missing LICENSE headers
2021-06-04 15:39:34 +02:00
Sylvestre Ledru
f421e51ad3
gnu/rm: fix tests/rm/rm{1,2}.sh
2021-06-04 09:12:42 +02:00
Sylvestre Ledru
aabef14404
gnu/rm: fix tests/rm/cycle.sh
2021-06-04 09:12:42 +02:00
Sylvestre Ledru
9cf3ab894f
gnu/ci: build in parallel
2021-06-04 09:12:42 +02:00
Sylvestre Ledru
a85ee4386a
gnu/rm: make the code reentrant
2021-06-04 09:12:39 +02:00
Mitchell Mebane
754082886c
dircolors: Address code review comments
2021-06-03 20:49:25 -05:00
Jan Scheer
130bf49e5d
Merge branch 'master' of github.com:uutils/coreutils into refactoring_parse_size
2021-06-03 22:32:34 +02:00
Sylvestre Ledru
6a8d15f92e
gnu/rm: match gnu's output
2021-06-03 22:19:14 +02:00
Sylvestre Ledru
84330ca938
gnu/test: rm: update one of the test to match what we do
2021-06-03 22:15:57 +02:00
Jan Scheer
db3ee61742
du/sort/od/stdbuf: make error handling of SIZE/BYTES/MODE arguments more consistent
...
* od: add stderr info for not yet implemented '--strings' flag
2021-06-03 21:00:03 +02:00
Jan Scheer
ad26b7a042
head/tail/split: make error handling of NUM/SIZE arguments more
...
consistent
* add tests for each flag that takes NUM/SIZE arguments
* fix bug in tail where 'quiet' and 'verbose' flags did not override each other POSIX style
2021-06-03 20:37:29 +02:00
Michael Debertol
6c46d09397
ln: canonicalize the parent directory of dst, not dst
...
dst may or may not exist. In case it exists it might already be a symlink.
In neither case we should try to canonicalize dst, only its parent directory.
https://www.gnu.org/software/coreutils/manual/html_node/ln-invocation.html
> Relative symbolic links are generated based on their canonicalized
> **containing directory**, and canonicalized targets.
2021-06-03 19:10:22 +02:00
Michael Debertol
af8f47ea6a
ln: remove redundant check
...
if `dst.exists()` and `settings.overwrite` is `OverwriteMode::Force`,
we already delete the file in the match above.
2021-06-03 16:30:45 +02:00
Sylvestre Ledru
841b689477
Merge pull request #2334 from sylvestre/crate_version
...
use crate_version!() instead of reading the env + rustfmt
2021-06-03 10:56:57 +02:00
Sylvestre Ledru
24032498ad
Merge pull request #2339 from sylvestre/gnu-compat
...
Improve the gnu compat and use it for "touch"
2021-06-03 10:53:47 +02:00
Sylvestre Ledru
963a0da0b4
Merge pull request #2288 from syukronrm/du-time
...
du: fix `--time` behavior
2021-06-03 07:56:41 +02:00
Sylvestre Ledru
5de623cfab
Merge pull request #2330 from miDeb/cp/close-fd
...
cp: close file descriptors after cow on linux
2021-06-03 07:54:34 +02:00
Syukron Rifail M
05aeaf3061
du: fix --time behavior
2021-06-03 08:18:23 +07:00
Sylvestre Ledru
31875a241f
touch/gnu compat: 'touch no-file' exit code should be 1
2021-06-02 23:50:35 +02:00
Sylvestre Ledru
eb2c06c37e
touch/gnu compat: when touch fails because of a permission error, change the error message
...
+ return 1 as error code when having this error
2021-06-02 23:48:16 +02:00
Sylvestre Ledru
e7f5916864
gnu/ci: allow to run a single gnu test (and document it)
2021-06-02 23:48:13 +02:00
Sylvestre Ledru
0105531b7f
show the backtrace in case of a rust crash
2021-06-02 23:37:34 +02:00
Jan Scheer
5898b99627
truncate: add error handling for SIZE argument
...
* add tests for SIZE argument
* fix clap argument handling for --size and --reference
2021-06-02 22:08:42 +02:00
Jan Scheer
2f5f7c6fa1
split: use "parse_size" from uucore
...
* make stderr of parsing SIZE/NUMBER argument consistent with GNU's behavior
* add error handling
* add tests
2021-06-02 21:32:41 +02:00
Michael Debertol
ed69d797b5
ln: reject --relative without --symbolic
2021-06-02 21:02:12 +02:00
Michael Debertol
87570bbc10
ln: remove redundant force
flag
...
This information is already encoded in the `OverwriteMode` enum.
2021-06-02 20:56:37 +02:00
Sylvestre Ledru
eb6e6d49eb
Merge pull request #2333 from tertsdiepraam/pr/fix-current-time-test
...
`pr`: fix usage of current time in tests
2021-06-02 20:09:50 +02:00
Michael Debertol
efa89de463
ln: fix LINK_NAME in help output
2021-06-02 19:58:29 +02:00
Michael Debertol
7ffc7d073c
cp: test that file descriptors are closed
2021-06-02 19:21:16 +02:00
Michael Debertol
e5c4681e04
tests: add the ability to set resource limits
2021-06-02 19:21:12 +02:00
Sylvestre Ledru
d8c06dd6bb
use clap::crate_version macro instead of the env variable
2021-06-02 19:00:19 +02:00
Sylvestre Ledru
6aa53ead7c
rustfmt the recent change
2021-06-02 18:43:35 +02:00
Terts Diepraam
48516cc06a
pr: fix usage of current time
2021-06-02 17:18:07 +02:00
Michael Debertol
dfaaa8c787
Merge branch 'master' of https://github.com/uutils/coreutils into cp/close-fd
2021-06-02 11:37:37 +02:00
Sylvestre Ledru
132ddf98b6
Merge pull request #2328 from miDeb/seq/validator
...
seq: reject NaN arguments
2021-06-02 11:20:13 +02:00
Sylvestre Ledru
f5b01a61cc
Merge pull request #2331 from miDeb/cp/linux-cow-errors
...
cp: show errors in cow on linux
2021-06-02 10:19:03 +02:00
Jan Scheer
6b8de1dd8b
sort: use "parse_size" from uucore
...
* make parsing of SIZE argument consistent with GNU's behavior
* add error handling
* add tests
2021-06-02 05:13:57 +02:00
Mitchell Mebane
850a56ccea
dircolors: rustfmt
2021-06-01 19:22:17 -05:00
Mitchell Mebane
efe1850087
dircolors: replace getopts with clap
...
Port argument parsing from getopts to clap.
The only difference I have observed is that clap auto-generates -h and
-V short options for help and version, and there is no way (in clap 2.x)
to disable them.
2021-06-01 19:22:08 -05:00
Michael Debertol
fc2b61eb96
tests: typo
2021-06-01 23:06:51 +02:00
Michael Debertol
a323e9cda1
cp: show errors in cow on linux
2021-06-01 23:06:38 +02:00
Jan Scheer
a900c7421a
od: use "parse_size" from uucore
2021-06-01 22:07:29 +02:00
Michael Debertol
23f89d1494
cp: close file descriptors after cow on linux
...
Instead of using into_raw_fd(), which transfers ownership and
requires us to close the file descriptor manually,
use as_raw_fd(), which does not transfer ownership to us but drops the
file descriptor when the original file is dropped (in our case at the
end of the function).
2021-06-01 22:04:19 +02:00
Michael Debertol
5329d77cc2
seq: adapt output to GNU seq
2021-06-01 20:35:18 +02:00