pixelb / fslint

Linux file system lint checker/cleaner
314 stars 74 forks source link

migrating to python3 and gtk3 #172

Open krthkj opened 3 years ago

krthkj commented 3 years ago

fslint is built using python2 and gtk2 (and some additional dependent libraries), these dependency are not satisfied in some of the latest Linux distributions, (especially Debian & Ubuntu based distro). Hence the ideal way to move forward is to migrate the application to python3 and gtk3.

P.S: will be creating a pull request from https://github.com/krthkj/fslint

qarmin commented 3 years ago

I already writing Rust based alternative for FSlint - https://github.com/qarmin/czkawka. You can "steal" glade file from it, since It seems to look similar to original(but require a lot of code changes since it looks similar but a lot of things are named different and doesn't work since I didn't put to it any logic) - https://github.com/qarmin/czkawka/blob/master/czkawka_gui/czkawka.glade

I already ported gtk2 glade file to be able to open it in Glade 3.36(from snap) which heavily increase my porting productivity since I can see how this is exactly done -fslint.glade.txt - just remove txt extension

qarmin commented 3 years ago

Already I released version 1.0.0 of my app czkawka, it have duplicates, empty folders, temporary and big files, but still lacks of some of fslint features.

altsalt commented 3 years ago

my app czkawka

I'm excited to give this a shot and glad that you're continuing to check back here. That said, I have mostly moved onto a different app, rmlint and wanted to point you towards it in case there was something useful to you there, or if hash comparisons were something you'd like to consider down the line. Good luck with the project!

mmardegan commented 3 years ago

my app czkawka

I'm excited to give this a shot and glad that you're continuing to check back here. That said, I have mostly moved onto a different app, rmlint and wanted to point you towards it in case there was something useful to you there, or if hash comparisons were something you'd like to consider down the line. Good luck with the project!

Thank you!

rbrito commented 3 years ago

@qarmin, Thank you for your program! Do you plan on implementing the remaining features fslint into your program? That would be awesome!

qarmin commented 3 years ago

I do not think that the tools available in FSLint and not yet implemented in Czkawka are used too often. So far my plan for the near future is to clean up the code so that in the future it will be easier to add other features (maybe those available in FSlint, although I doubt it) and rewrite the program to GTK4. At the moment I'm simultaneously developing another program for mass file renaming.

rbrito commented 3 years ago

Hi, @qarmin.

I do not think that the tools available in FSLint and not yet implemented in Czkawka are used too often.

Actually, at least the "invalid names" (for when I get files from collaborators) and "remove whitespaces" are features that I use frequently.

Regarding the UI of Czkawka that you posted, in the duplicates window, I can't tell if hardlinking and/or symlinking is supported (not only deleting duplicates). That is one of the best features of the duplicate finder feature of fslint, IMVHO.

So far my plan for the near future is to clean up the code so that in the future it will be easier to add other features (maybe those available in FSlint, although I doubt it) and rewrite the program to GTK4.

Is GTK4 a pressing need (at least for now)? So far, in Debian, GTK 4 is present in the experimental distribution and the only reverse dependencies are packages from GTK4 itself.

Thanks,

Rogério Brito.

qarmin commented 3 years ago

With GTK 4 I will probably wait for Ubuntu 22.04.

Invalid names from FSlint is available on Czkawka as Duplicate finder by name, just instead setting $PATH by checkbox, you need to manually select path which are inside $PATH folder.

Czkawka for now support only symbolic links.

I'm not sure how exactly works "Remove whitespaces" feature - it works for all type of files or text ones? If for text ones, how they are recognized? Mime types? This feature also will force to add additional button(Clean or similar) and logic behind it.

ykurlaev commented 2 years ago

Was there any progress in porting to python3 recently?

insaner commented 1 year ago

For those interested, I have started the work, but there's still much to fix before it works at all. I have pushed what I have so far to my fork, in the hopes others can help me out in this.

https://github.com/insaner/fslint

Python 3 migration I think is complete, but the glade file still needs to be fixed before fslint is able to launch.


Czkawka is looking great, but it didn't work for me as a replacement for fslint, unfortunately.

insaner commented 1 year ago

If someone is able to help editing the glade file, especially in converting the sections where GtkClist needs to be changed to GtkTreeView that would greatly help in migrating to gtk3 (as this is currently beyond my ability).

I can get most of the gui to show the old familiar fslint interface by running

glade-previewer --filename fslint.glade

but the script still will not run, failing with

AttributeError: 'list' object has no attribute 'get_widget'