03d41e173f
If the user could not create a hard link (due to permissions or different block devices) then czkawka lost the duplicate file. ``` $ mkdir hardlink $ cd hardlink $ echo a > a $ cp a b $ chown thetestuser:thetestuser a $ ls -il . 25169246 -rw-rw-r-- 1 thetestuser thetestuser 2 Feb 7 11:18 a 25169641 -rw-rw-r-- 1 thomas thomas 2 Feb 7 11:18 b $ cargo run --bin czkawka_cli dup --directories $(pwd) -m 1 -f test101.result --delete-method HARD [...] -------------------------------WARNINGS-------------------------------- Failed to link /home/thomas/Development/czkawka/hardlink/b -> /home/thomas/Development/czkawka/hardlink/a ---------------------------END OF WARNINGS----------------------------- $ ls -il . 25169246 -rw-rw-r-- 1 thetestuser thetestuser 2 Feb 7 11:18 a ``` Now czkawka keeps all files and the warning provides more information why czkawka can't replace the duplicate with a hard link. ``` $ cargo run --bin czkawka_cli dup --directories $(pwd) -m 1 -f test101.result --delete-method HARD -------------------------------WARNINGS-------------------------------- Failed to link /home/thomas/Development/czkawka/hardlink/b -> /home/thomas/Development/czkawka/hardlink/a (Operation not permitted (os error 1)) ---------------------------END OF WARNINGS----------------------------- [...] 25169246 -rw-rw-r-- 1 thetestuser thetestuser 2 Feb 7 11:18 a 25169641 -rw-rw-r-- 1 thomas thomas 2 Feb 7 11:18 b ``` |
||
---|---|---|
.. | ||
big_file.rs | ||
broken_files.rs | ||
common.rs | ||
common_directory.rs | ||
common_extensions.rs | ||
common_items.rs | ||
common_messages.rs | ||
common_traits.rs | ||
duplicate.rs | ||
empty_files.rs | ||
empty_folder.rs | ||
invalid_symlinks.rs | ||
lib.rs | ||
same_music.rs | ||
similar_images.rs | ||
temporary.rs | ||
zeroed.rs |