~rjarry/aerc#83: 
Attach glob "*" should not show hidden files.

Currently, if you go :attach * every file, including hidden files are shown.

Status
RESOLVED IMPLEMENTED
Submitter
~ferdinandyb
Assigned to
Submitted
1 year, 12 days ago
Updated
9 months ago
Labels
bug

~ferdinandyb 9 months ago

I poked around a bit: line 314 in utils:

matches, err := filepath.Glob(fmt.Sprintf("%s*", path))

we use this to return partial matches when the user is typing out a path.

It uses the syntax of match: https://pkg.go.dev/path/filepath#Match which says nothing about skipping hidden files. It also doesn't say anything about exclusions.

What we could do is check if the users has explicitly included a . at the beginning and if not, strip anything starting with a . from the results, but I don't know if this is desirable or not.

~poldi1405 9 months ago

~poldi1405 REPORTED IMPLEMENTED 9 months ago

Moritz Poldrack referenced this ticket in commit 466888d.

Register here or Log in to comment, or comment via email.