IgnorantGuru / spacefm

SpaceFM File Manager
http://ignorantguru.github.com/spacefm/
GNU General Public License v3.0
487 stars 73 forks source link

Files in .hidden are not shown even when "Hidden Files" view is enabled #761

Open dnut opened 4 years ago

dnut commented 4 years ago
touch test
echo test >> .hidden

Toggling the "Hidden Files" setting in the view menu will make .hidden appear and disappear from view, but test will always remain hidden despite the hidden setting. These files should become visible when hidden files are in view.

ncmprhnsbl commented 4 years ago

this is by design, the "Hidden Files" toggle is only for .dot files and files listed in .hidden are only shown when removed from that list. it's a (very thin) layer of security..

dnut commented 4 years ago

I am very skeptical that this was by design. It would be a terrible design. Security is irrelevant to this. Isn't it obvious that when the user wants to view hidden files, they want to see all hidden files, not just the ones that are hidden with some specific mechanism that is not mentioned anywhere in the UI. Other file managers treat hidden files in the way I expect. Even if this is intentional behavior, it should at least say "Dot Files," not "Hidden Files." But that would be a really weird feature that isn't as useful.

ncmprhnsbl commented 4 years ago

not suggesting it's a great design or otherwise. it's explained pretty clearly when you use the >actions>hide entry

The names of the selected files will be added to the '.hidden' file located in this folder, which will hide them from view in SpaceFM. You may need to refresh the view or restart SpaceFM for the files to disappear.

To unhide a file, open the .hidden file in your text editor, remove the name of the file, and refresh.

afaik other file managers only hide/unhide .dot files, whereas this can "hide" any file. EDIT: well, apparently they do.. if you look with ls, you see how not hidden such a file is.

dnut commented 4 years ago

The names of the selected files will be added to the '.hidden' file located in this folder, which will hide them from view in SpaceFM. You may need to refresh the view or restart SpaceFM for the files to disappear. To unhide a file, open the .hidden file in your text editor, remove the name of the file, and refresh.

This doesn't say anything about the "View > Hidden Files" option though. SpaceFM could have the behavior I recommend, and this documentation would still be accurate. Viewing a hidden file is consistent with the file still being "hidden" from normal view in the same way dotfiles are hidden.

I think it was an oversight, in that it did not occur to the developer to apply the logic for "View > Hidden Files" to .hidden.

afaik other file managers only hide/unhide .dot files, whereas this can "hide" any file. EDIT: well, apparently they do.. if you look with ls, you see how not hidden such a file is.

Thunar, Nemo, and Nautilus all behave the way I expect. PCManFM actually just ignores the contents of .hidden, which explains why SpaceFM had to come up with its own implementation. So SpaceFM is totally unique in this behavior.