Skip to content

Conversation

matrixhead
Copy link
Contributor

@matrixhead matrixhead commented Apr 4, 2024

This pr tries to fix #6158

  • changed the behavior of how -b worked. Now, VERSION_CONTROL env is considered before resorting to --backup=existing
  • added more checks to is_forbidden_to_copy_to_same_file
  • added some more cases in copy_file so that it's okay to return without an error in some cases
  • fixes the issue of cp not dereferencing the destination symlink when -d is given without -b, by only removing destination files that are only part of a hard link
  • fixed the error caused by trying to remove a file that's already been removed

@matrixhead matrixhead marked this pull request as draft April 4, 2024 18:29
@matrixhead matrixhead changed the title cp: backup, hardlink fixes cp: gnu "same-file" test case compaitablity Apr 4, 2024
@cakebaker cakebaker changed the title cp: gnu "same-file" test case compaitablity cp: gnu "same-file" test case compatibility Apr 5, 2024
Copy link

github-actions bot commented Apr 7, 2024

GNU testsuite comparison:

Skipping an intermittent issue tests/rm/rm1 (passes in this run but fails in the 'main' branch)
Skipping an intermittent issue tests/tail/inotify-dir-recreate (passes in this run but fails in the 'main' branch)
Congrats! The gnu test tests/cp/cross-dev-symlink is no longer failing!

Copy link

GNU testsuite comparison:

Congrats! The gnu test tests/cp/cross-dev-symlink is no longer failing!

Copy link

GNU testsuite comparison:

Skip an intermittent issue tests/tail/inotify-dir-recreate (fails in this run but passes in the 'main' branch)
Congrats! The gnu test tests/cp/same-file is no longer failing!

@matrixhead matrixhead force-pushed the main branch 2 times, most recently from 33e08e0 to 5c8b54e Compare April 14, 2024 08:42
Copy link

GNU testsuite comparison:

Skipping an intermittent issue tests/tail/inotify-dir-recreate (passes in this run but fails in the 'main' branch)

Copy link

GNU testsuite comparison:

Congrats! The gnu test tests/cp/same-file is no longer failing!
Congrats! The gnu test tests/cp/cross-dev-symlink is no longer failing!

@matrixhead matrixhead marked this pull request as draft April 15, 2024 17:15
@matrixhead matrixhead marked this pull request as ready for review April 15, 2024 17:38
@matrixhead matrixhead requested a review from sylvestre April 17, 2024 04:15
@sylvestre
Copy link
Contributor

well done, just a small last request :)

@matrixhead
Copy link
Contributor Author

thanks 😃 will do that

@matrixhead matrixhead force-pushed the main branch 3 times, most recently from e55de16 to 3360ebc Compare April 17, 2024 11:20
Copy link

GNU testsuite comparison:

Skipping an intermittent issue tests/tail/inotify-dir-recreate (passes in this run but fails in the 'main' branch)

Copy link

GNU testsuite comparison:

Congrats! The gnu test tests/timeout/timeout is no longer failing!

@matrixhead matrixhead requested a review from sylvestre April 19, 2024 04:45
@sylvestre
Copy link
Contributor

looks great
I am wondering why it isn't displayed that same-file.sh passes now
2024-04-17T11:36:56.7867661Z PASS: tests/cp/same-file.sh

Copy link

GNU testsuite comparison:

Skip an intermittent issue tests/tail/inotify-dir-recreate (fails in this run but passes in the 'main' branch)
Congrats! The gnu test tests/cp/same-file is no longer failing!
Congrats! The gnu test tests/cp/cross-dev-symlink is no longer failing!

@matrixhead
Copy link
Contributor Author

matrixhead commented Apr 19, 2024

@sylvestre just to clarify we are talking about github-actions not commenting "Congrats!" message right?
edit: my initial thoughts are maybe it's comparing wrong test logs.

@sylvestre sylvestre merged commit a171743 into uutils:main Apr 21, 2024
@sylvestre
Copy link
Contributor

well done :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

cp: making cp compatible with "same-file" gnu test case
2 participants