sindresorhus / hide-files-on-github

Chrome extension - Hide nonessential files from the GitHub file browser
https://chrome.google.com/webstore/detail/hide-files-on-github/lpnakhpaodhdkleejaehlapdhbgjbddp
MIT License
320 stars 35 forks source link

Suggestion: Hide .gitkeep files #81

Closed Alexejhero closed 5 years ago

Alexejhero commented 5 years ago

Cross-posted from sindresorhus/refined-github#2208


Suggestion

In some repos, there may be empty folders containing a .gitkeep file. This is usually done so that the folders appear in the repo, even though they dont contain any files (maybe the folders themselves store information in their name).

The link to open the folder is redundant because inside it there is only a 0 KB .gitkeep file.

Refind github could check if there is only one file in the folder and if it has 0 KB, and if that is the case, completely remove the link to open the folder.

Example URL

https://github.com/AlexejheroYTB/Dlockly/tree/master/blocks/custom

Example of folder that this could apply to: 002 [sep]'

Images

This feature could look something like this:

image

fregante commented 5 years ago

Just one problem: this would require an API call, which would slow down the hiding. Currently it's great because you never see the list of files. #78

fregante commented 5 years ago

Closing for that reason, it would require a rewrite that would make it slower