EXTRA files finder
EXTRA files finder is the application of the future that allows you to find all files duplicates and delete unnecessary copies!
Contents
- Instruction of use
- Quickstart
- Used tecnhologies
- Idea of the solution
- Files description
- Contributors
- License
📖 Instruction of use
- First screen is this. Tap on the folder icon at the left-upper conner and select directory!
- Select it and click "choose".That will be the directory for finding duplicated files.
- After fast scanning for getting all files-paths and clustering them by sizes, you can see in the real-time the result of the application work process. You can choose clusters at the left half of the screen or click "Stop" to temporarily stop the work process. Notice that you can see the progress bars and timings at the bottom of the application!
- You can double-click on a cluster at the left side to open it and look at the right side files of that cluster. Now you can select some of them and delete (* check important) or open path/open file
- Different sort modes are available. You can click on column header to sort clusters by values there. "##" means the amount of copies at this cluster, "Mem" means the one file's size of this cluster and "Extra" means how much can you free if you delete all copies except one (that is (count_files - 1) * one_file_size).
- You can open path or even file if you want just by clicking the proper button!
Important if you want to be able to delete files, then uncomment the line 462 at mainwindow.cpp
$ //QFile(item->text(2)).remove(); // TODO: IS OFF TO DON'T DELETE SOMETHING IMPORTANT
Important app shows all interesting files that have analogs of the same size. It means sometimes it shows you files with NO COPIES. It's lifehack and I'm sure app should work so.
🚀 Quickstart
You have two options:
CMake-way building:
$ cmake -DCMAKE_BUILD_TYPE=Debug .
$ make
You are also free to write if you want, for example, -DCMAKE_BUILD_TYPE=RelWithDebInfo
instead of -DCMAKE_BUILD_TYPE=Debug
QMake-way building:
$ qmake CONFIG+=debug -o Makefile extra_files_finder.pro
$ make
To run it just write in your terminal:
$ ./extra_files_finder
📋 Used technologies
- QT framework - for UI application and multi-threading
- C++ - as the language for a backend development
🎉 Idea of the solution
Ok, that is very easy to describe:
- We cluster files by their sizes by the method
clustering::cluster_by_size
- Then we compare files of the same size by their hashes Sha3_256
📂 Files description
Code of the application:
main.cpp
- file with functionmain
mainwindow.h
,mainwindow.cpp
- the code of the main applicationclustering.cpp
,clustering.h
- for the first step in our ideaclusterWorker.cpp
,clusterWorker.h
- for the second step. It starts in an extra thread bymainwindow.cpp
to don't disturb UI-thread
Also:
mainwindow.ui
— XML-file with the description of the main window. Utilityuic
uses it for the building of the fileui-mainwindow.h
, which includes tomainwindow.cpp
.ui
-files can be opened by QT Designer or QT Creator.CMakeLists.txt
—cmake
's build-script.extra_files_finder.pro
—qmake
's build-script.
👪 Contributors Ivan Sorokin, JetBrains C++ developer. C++ master developer. Author of the app's idea and the app base creator
Evgeniy Nemchenko, VK.com developer. Code reviewer. Adviced how to decrease the code complexity and what features we can add more
Igor Kolobov. Also a code reviewer. Adviced how to decrease the code complexity and what features we can add more
Nikita Lisovetin, student of ITMO University, Department of Computer Technologies. Developer. Wrote the code
📄 License
Extra Files Finder is MIT licensed, as found in the LICENSE file.