Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: implemented hideDotfiles feature in the backend #1148

Merged
merged 5 commits into from
Nov 20, 2020

Conversation

kwsp
Copy link
Contributor

@kwsp kwsp commented Nov 14, 2020

This PR addresses #1084.

Per @o1egl, I've rewritten my previous PR (#1085) to move the filtering logic to the backend.

By default the hideDotfiles options is turned off, and it can be turned on in profile settings.

rules/rules.go Outdated Show resolved Hide resolved
@kwsp
Copy link
Contributor Author

kwsp commented Nov 18, 2020 via email

@o1egl
Copy link
Member

o1egl commented Nov 18, 2020

Prefix based comparison is much faster than the regexp.

Copy link
Member

@o1egl o1egl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit

rules/rules.go Outdated Show resolved Hide resolved
rules/rules_test.go Outdated Show resolved Hide resolved
kwsp and others added 2 commits November 18, 2020 22:36
Use `strings.HasPrefix` to avoid panic on empty string.

Co-authored-by: Oleg Lobanov <oleg@lobanov.me>
test naming convention

Co-authored-by: Oleg Lobanov <oleg@lobanov.me>
rules/rules_test.go Outdated Show resolved Hide resolved
Co-authored-by: Oleg Lobanov <oleg@lobanov.me>
@kwsp
Copy link
Contributor Author

kwsp commented Nov 19, 2020

Any more changes needed?

@o1egl o1egl merged commit 10e399b into filebrowser:master Nov 20, 2020
mitsukileung added a commit to mitsukileung/filebrowser that referenced this pull request Nov 21, 2020
@smithzss
Copy link

@NieTiger @o1egl Is this a configurable option when launching in a docker container? I looked in the source and I didn't see anything that would suggest it, but I wanted to ask to confirm. Didn't see it in the documentation as well. I am looking for dotfiles to be hidden by default. Appreciate the help! Thanks.

@o1egl
Copy link
Member

o1egl commented Jan 20, 2021

@smithzss this param is only available in the UI.

@pdesgarets
Copy link

@o1egl would you consider a PR implementing a flag for this param in the Cmd ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants