Commit graph

5627 commits

Author SHA1 Message Date
Sylvestre Ledru
32d281bbcc
Merge pull request #2544 from miDeb/sort/delete-tmps
sort: delete temporary files when sort is terminated
2021-08-06 11:52:06 +02:00
Michael Debertol
0ae9e10ed3 sort: delete the temporary directory when sort is terminated
When hitting Ctrl+C sort now deletes any temporary files. To make this easier I
created a new struct `TmpDirWrapper` that handles the creation of new temporary
files and the registration of the signal handler.
2021-08-06 11:29:24 +02:00
Sylvestre Ledru
966aa8e0c8
Merge pull request #2075 from koutheir/master
chcon: added implementation and integration tests
2021-08-06 09:26:50 +02:00
Sylvestre Ledru
50b9d9f9a3
Merge branch 'master' into master 2021-08-06 09:26:39 +02:00
Sylvestre Ledru
76222d52ca
Merge pull request #2547 from miDeb/basenc
basenc: add utility
2021-08-06 08:48:49 +02:00
Sylvestre Ledru
a76be9cb1e
Merge pull request #2548 from miDeb/chown/test
chown: fix unit test
2021-08-06 08:43:07 +02:00
Koutheir Attouchi
090be5bb94 chcon: added implementation and integration tests
The ToDo list was updated to mark `chcon` as done.

Building and testing `chcon` requires enabling the `feat_selinux` feature. If `make` is used for building, then please specify `SELINUX_ENABLED=1` if building and testing on a system where SELinux is not enabled.
2021-08-05 22:57:57 -04:00
Michael Debertol
b8c383e210 basenc: add utility
basenc is a brand-new gnu core utility (added less than 3 years ago!),
which enables some more encodings.
2021-08-06 00:07:19 +02:00
Michael Debertol
ac6356087e chown: fix unit test 2021-08-06 00:03:04 +02:00
Sylvestre Ledru
63fd139b04
Merge pull request #2524 from FelipeLema/uresult-cat-2464
migrate `cat` code to UResult #2464
2021-08-06 00:02:17 +02:00
Sylvestre Ledru
158a8a387b
Merge pull request #2545 from miDeb/maint/arch-gnu-test
maint: enable gnu test for arch
2021-08-05 20:51:53 +02:00
Michael Debertol
22306db161 maint: enable gnu test for arch
Gnu checks before testing a utility whether that utility was actually built.
It thinks `arch` was not built, even though it was.

This patch does not convince gnu that `arch` was built (I wasn't able to figure that out),
but instead comments out the check in `init.cfg` when running `build-gnu.sh`.
2021-08-05 00:42:41 +02:00
Sylvestre Ledru
54f4c8ff35
Merge pull request #2474 from backwaterred/master 2021-08-04 22:48:54 +02:00
backwaterred
2c41838166
Merge branch 'uutils:master' into master 2021-08-04 12:47:47 -07:00
Tyler
0864234e3d Removes unused macros from windows & macos builds 2021-08-04 12:47:03 -07:00
Sylvestre Ledru
92ccfa86b0
Merge pull request #2546 from miDeb/base/gnu-tests
base32/64: make the gnu test pass
2021-08-04 09:25:18 +02:00
Tyler
67059db086 Merge branch 'uutils-master-2' 2021-08-03 17:34:21 -07:00
Tyler
601c9fc620 Merge branch 'master' of https://github.com/uutils/coreutils into uutils-master-2 2021-08-03 17:33:43 -07:00
Tyler
7ed7c840bd Fix clippy warnings and build issues. Defer NL to seperate issue. 2021-08-03 17:18:34 -07:00
Tyler
e1fcc85b0a Merge branch 'master' of github.com:backwaterred/coreutils 2021-08-03 16:39:17 -07:00
Michael Debertol
319b984434 gnu-test: base32/64: modify test expectation for invalid inputs
When decoding an invalid base32/64 string, gnu writes everything it was
able to decode until it hit the decode error, while we don't write
anything if the input is invalid.
2021-08-04 00:19:41 +02:00
Michael Debertol
9700f0503d base32/64: adjust error message to match gnu 2021-08-04 00:04:25 +02:00
Michael Debertol
44ae927969 base32/64: print the first extra operand, not the one before
Only one operand is allowed, so when there are multiple arguments we
should print the second argument in the error.
2021-08-03 23:37:20 +02:00
Sylvestre Ledru
26cc2ed440
Merge pull request #2517 from jfinkels/tac-null-separator
tac: support null separator (-s "")
2021-08-03 09:22:50 +02:00
Sylvestre Ledru
afb2e422fd
Merge pull request #2529 from jfinkels/tests-improve-link-arg-names
tests: better arg names in link helper functions
2021-08-03 09:21:36 +02:00
Sylvestre Ledru
91d48d137d readme: update of the min rust version in the doc 2021-08-02 23:38:41 +02:00
Sylvestre Ledru
b877486265
Merge pull request #2438 from jhscheer/id_selinux_context
id: add support for showing SELinux context (--context/-Z)
2021-08-02 23:36:09 +02:00
Jan Scheer
8232c1c64d
id: increase MSRV in order to compile selinux crate
* Bump MSRV from 1.43 to 1.47 in order to be able to compile
`selinux` crate 0.1.3

* Bump MSRV for clippy to 1.47

* Add "selinuxlib" to spell-checker
2021-08-02 20:36:06 +02:00
Jan Scheer
010565c8fb
Merge branch 'master' into id_selinux_context 2021-08-02 10:40:45 +02:00
Sylvestre Ledru
950076fd23
Merge pull request #2543 from miDeb/sort/uresult
sort: use UResult
2021-08-02 08:26:43 +02:00
Felipe Lema
5646c81332 correct clippy issues, RustFmt 2021-08-01 23:55:30 -04:00
Jeffrey Finkelstein
2a4c0a867a tests: better arg names in link helper functions
Change the argument names in

* `AtPath::hard_link()`,
* `AtPath::symlink_file()`, and
* `AtPath::symlink_dir()`,

from `src` and `dest` to `original` and `link` to match the arguments of
the corresponding functions from the Rust standard library. For example,
see `std::os::unix::fs::symlink()`.
2021-08-01 19:50:58 -04:00
Jeffrey Finkelstein
d74fb62df7 tac: support null separator 2021-08-01 19:47:21 -04:00
Sylvestre Ledru
24b1822cba
Merge pull request #2468 from thomasqueirozb/tail_stdin
tail: handle `-` as an alias for stdin
2021-08-02 00:24:28 +02:00
Michael Debertol
a4709c805c sort: use UResult 2021-08-01 23:22:29 +02:00
Thomas Queiroz
53b16e9b43 docs/spell: add 'Thomas Queiroz' to spell-checker exceptions word list 2021-08-01 17:20:30 -04:00
Thomas Queiroz
6127ea9642 tests/tail: add test for as an alias for stdin 2021-08-01 17:20:30 -04:00
Thomas Queiroz
940559f0e1 tail: handle - as an alias for stdin 2021-08-01 17:20:24 -04:00
Sylvestre Ledru
80712415d6
Merge pull request #2538 from miDeb/sort/input-is-output
sort: handle cases where the output file is also an input file
2021-08-01 22:49:14 +02:00
Michael Debertol
e8eb15f05e core/error: require UCustomError to be Send
For multi-threaded programs like sort it is necessary to be able to send
errors between threads.
2021-08-01 21:27:59 +02:00
Michael Debertol
450a487d76 sort: ignore broken pipes in a test
Since sort exits early due to the nonexistent file, it might no longer
be around when we try to send it the input.
This is "by design" and can be ignored.
2021-08-01 18:02:52 +02:00
Michael Debertol
af47c66a00 sort: improve tests 2021-08-01 17:12:35 +02:00
Michael Debertol
3d23ace9b8 sort: remove redundant comment 2021-08-01 17:12:06 +02:00
Sylvestre Ledru
2d84c68f20
Merge branch 'master' into sort/input-is-output 2021-08-01 13:51:19 +02:00
Sylvestre Ledru
11d03bffd3
Merge pull request #2539 from miDeb/sort/args-exit-code
sort: do not exit with failure for "--version" or "--help"
2021-08-01 13:50:48 +02:00
Sylvestre Ledru
6ccba08729
Merge pull request #2540 from ycd/ln-uresult
feat(ln): use UResult
2021-08-01 13:50:24 +02:00
Yagiz Degirmenci
95a890e5f8 chore(ln): fix clippy errors
Signed-off-by: Yagiz Degirmenci <yagizcanilbey1903@gmail.com>
2021-08-01 01:42:12 +03:00
Yagiz Degirmenci
65dd6afa13 chore(ln): delete comment
Signed-off-by: Yagiz Degirmenci <yagizcanilbey1903@gmail.com>
2021-08-01 01:27:25 +03:00
Yagiz Degirmenci
55d1dc78b0 feat(ln): use UResult
Signed-off-by: Yagiz Degirmenci <yagizcanilbey1903@gmail.com>
2021-08-01 01:25:21 +03:00
Michael Debertol
663c9751a1 sort: do not exit with failure for "--version" or "--help" 2021-08-01 00:05:08 +02:00