5 ms·
I think "hidden" files are a bad idea. What's the point of hiding some of the files in a directory from user? It only makes things more confusing. For example
by codedokode 4y ago
I think "hidden" files are a bad idea. What's the point of hiding some of the files in a directory from user? It only makes things more confusing.
For example the folder might look empty but in fact it could contain thousands of hidden files. You want to delete it as it is empty but accidentally delete important system files.
Even worse, imagine if all files on an USB drive are marked as hidden. You see that the drive is empty but when you attempt to copy something to it see a message that there is no free space.
One more example. Imagine if you have a project and want to edit an .env file. But as dotfiles are hidden in Linux you don't see this file and cannot open it. It turns out that Windows Explorer which doesn't hide dotfiles is much better for developing projects with Docker!
There should be no hidden files. We cannot do anything with Windows and their MS-DOS legacy but Linux could stop hiding dotfiles in GUI and CLI commands.
- 8n4vidtmkvmk 4y agoi just always list dotfiles for years now.. and my IDEs too. mostly a non issue.
- codedokode 4y agoAnd I have to enable showing them on every system I work with (and add -a to every ls command, and google which option enables incldues them in pattern expansion). That is annoying.
- 8n4vidtmkvmk 4y agoWell.. ya. I set up my aliases and then forget about it again. Globbing is mildly annoying but i think there's a dotglob option or something you can set
- klodolph 4y agoHidden files on MacOS were used sparingly—the main instance of a hidden file is the file which stores an icon for a folder, if the folder has a custom icon. Hidden files are only hidden from the UI, they appear normally in the command line. The standard Unix folders (usr, var, etc) are also hidden—to be honest, this is a compromise because the Unix filesystem hierarchy sucks, but we are saddled with it for backwards compatibility reasons. I did appreciate the relative clarity of old macOS systems—everything in the OS was in “System Folder”, the rest of the filesystem was yours, and you could freely move applications without breaking anything, uninstall them by putting them in the trash, etc.
- codedokode 4y agoHiding thumbnails cache is bad because a user might believe that the USB drive is empty and doesn't have any confidential data but the thumbnails cache might still have them. There is no need to hide such files. Just display them as system files in Explorer. > The standard Unix folders (usr, var, etc) are also hidden Again there is no need to do it. Just move them to a directory named "System files".
- klodolph 4y agoYou can’t move “var” to a “System files” folder. This would break programs which expect /var to be, well, at /var. Long ago on macOS, everything was in “System Folder”, and it worked fine, but macOS has since inherited a massive Unix legacy. Thumbnail caches are not stored on USB drives, they’re stored somewhere else, away from your files.
- rollcat 4y agoFor people out there on macOS, you can press Cmd-Shift-dot in Finder to toggle displaying any hidden files (including the standard UNIX hierarchy at /). By the way, I'm pondering setting my XDG_*_HOME vars on Linux/BSD to use the macOS paths like ~/Library, just to see if the standard is actually being followed.
- medstrom 4y agoI did a similar thing. I set XDG_CONFIG_DIR=~/ (normally ~/.config/). It works surprisingly well, though I encountered some edge cases that eventually made me give up. Also some programs don't know about XDG_CONFIG_DIR and just hardcode ~/.config/, but you can symlink ~/.config/ -> ~/.
- waste_monk 4y ago>What's the point of hiding some of the files in a directory from user? It only makes things more confusing. If a user doesn't know what .ssh/ or .bash_history are, and it can hurt them to accidentally delete or modify them, why show them by default? It's like training wheels on a bike. >For example the folder might look empty but in fact it could contain thousands of hidden files. You want to delete it as it is empty but accidentally delete important system files. If it is possible for a regular user to accidentally brick a system like this, it was doomed to begin with. If a user doesn't know what a dotfile is they shouldn't have administrative privileges, and if they do get them there is no safeguard to stop them destroying the system. It's not a dotfile issue. >Imagine if you have a project and want to edit an .env file. But as dotfiles are hidden in Linux you don't see this file and cannot open it. It turns out that Windows Explorer which doesn't hide dotfiles is much better for developing projects with Docker! In what reality is someone developing software and building Docker containers who doesn't understand the concept of hidden files? Seems awfully contrived.
- jl6 4y ago> If a user doesn't know what .ssh/ or .bash_history are, and it can hurt them to accidentally delete or modify them, why show them by default? It's like training wheels on a bike. This is really the problem with the home directory. It’s supposed to be the place where the user puts their files, but it’s also a place where applications put their files, usually without asking the user. The battle is lost - the home directory territory should be ceded to applications and the user should have a separate space in which to manage their files. This can sort of be achieved with the $XDG_CONFIG_HOME environment variable, but not all software respects it, so in practical terms it’s a lot easier just to leave $HOME to be the application config dumping ground.
- delta_p_delta_x 4y agoIt kind of goes around to the same point: developers are sloppy and assume that ~ or %USERPROFILE% has full read-write permissions, and treat the corresponding home directories as a free-for-all dumping ground.
- 4y ago
- delta_p_delta_x 4y agoPersonally, I think hidden files are OK, but we have lousy defaults, regardless of OS. By default, Explorer hides hidden files (and goes one step further and doesn't display file extensions: why???), so do Finder, Dolphin, Nautilus, and even `ls` by default.
- Milner08 4y agoWell yeah.. because they are hidden files. They wouldn't be hidden files if the default wasn't to hide them...
- Already__Taken 4y agohidden file extensions by default are to "save" users from renaming files and borking the extension. Later windows UX improved the renaming to help avoid selecting the extension. file extensions are the mistake here really not them being hidden.
- donatj 4y agoExecutability based on extension combined with hidden extensions is imho one of Windows biggest mistakes. Make an exe, give it the icon of a word document - no way for a layperson to know it’s a trick.
- maicro 4y ago"Show hidden files" and "show extensions for known file types" are two folder options I enable on any Windows system I touch / within a few minutes of installation. I'll take a bit of extra visual clutter if it means I can actually see what all is in a folder, vs. just assuming I know.
- annowiki 4y agoWhen I run ls I don't want to see all the configuration files. Just my files. I think that's the point of hidden files. > One more example. Imagine if you have a project and want to edit an .env file. But as dotfiles are hidden in Linux you don't see this file and cannot open it. How likely is it that someone is going to want to edit a .env file and not know how to view hidden files?
- jstanley 4y ago> When I run ls I don't want to see all the configuration files. Just my files. Well then configuration files can simply not be in the same directory as your files. Easy fix.
- SAI_Peregrinus 4y agoYour user doesn't have permissions to write to any directory that isn't yours. It doesn't mean configs have to be in your "documents" directory, but they do have to be in with your files!
- jstanley 4y agoThe comment I was responding to was talking about the utility of files being hidden. But they don't need to be hidden by being special, they can just be "hidden" by living in a subdirectory that you don't look inside.
- psd1 4y agoRe accidental deletion, ntfs also has a "system" flag. Windows prompts if you delete one of those.