elementary / files

File browser designed for elementary OS
https://elementary.io
GNU General Public License v3.0
322 stars 75 forks source link

Feature Request: Add power user mode with enhanced features #2085

Open spotlesscoder opened 1 year ago

spotlesscoder commented 1 year ago

Problem

I want to binary diff two files in the download section to verify that the downloaded file equals binary the original file I uploaded before

Proposal

I want a per-user setting in elementary OS files that each user can enable optionally via gsettings. That should be called "power user mode" or something like that.

When enabled, I want the default right click menu in the main viewport to have an additional sub-menu with additional features. One feature that would be very useful is triggering a byte-level comparison of two currently selected files.

When power save mode is on (introduced with eOS 7 IIRC), a warning should be displayed for files over (200M?) as reading and comparing large files will likely drain the battery a lot.

(optionally: if more than 2 files are selected, display a table with each filename as both rows and columns and mark the cells of matching pairs with "x". To save compute power, compare the files sequentially - if A matches B and also C, we don't need to compare A and B as well as B and C and A and C - we only need to compare A and B and B and C - then we know that A and C must also be same)

Prior Art (Optional)

No response

jeremypw commented 1 year ago

I cannot see the suggested dual-mode UX being approved tbh bearing in mind that dual-mode click handling was discontinued. A possible alternative would be to provide contracts for advanced functions which could be optionally installed. An example of such a function can be found here https://github.com/jeremypw/gpg_wrapper and there may be others in other repos. Not sure how these would be distributed though as they cannot be flatpaked.

jeremypw commented 1 year ago

As you are probably aware you can do a byte comparison with cmp -b FILE1 FILE2 in the terminal. You can copy & paste the selected files from Files into a terminal after the command although you have to manually replace the newline between the pasted files with a space which is annoying.

jeremypw commented 1 year ago

Another option is a set of optional plugins like Code but unless and until an AppMenu for Files is approved that won't work as it needs UX to select which plugins you want.

spotlesscoder commented 1 year ago

Thx :) Do you know whether cmp supports 2+ files with the optimization I thought of (or even better optimization?)

spotlesscoder commented 1 year ago

the code app might not be the most appealing solution for people without programming experience and might scare them a bit away from using the feature

jeremypw commented 1 year ago

man cmp indicates that cmp is limited to comparing 2 files, although there are a number of other options.

There is the command diff3 that compares 3 files but that is intended for text files only. Type man diff3 into terminal for further info.

jeremypw commented 1 year ago

I am only looking at built in commands available oob. No doubt there are others that could be installed.

jeremypw commented 1 year ago

Probably best to create separate issues for each feature you feel Files is lacking and which could be useful to a significant number of users. There is no agreed definition of a "power user" unfortunately. Users comfortable using a terminal they can probably get what they want done anyway.