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

Feature Request: Flexible File Search #51

Open
augustus-thomas opened this issue Mar 1, 2024 · 0 comments
Open

Feature Request: Flexible File Search #51

augustus-thomas opened this issue Mar 1, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@augustus-thomas
Copy link
Owner

Reasoning

Most file systems currently deployed help the end user search the contents of files in a directory. Keywork search is a major subdomain of computer science precisely because software developers are interested in making fast and reliable searches on content. Some companies have built their entire company on quick and accurate file content search. Data storage, manipulation, and retrieval are arguably the only reasons people use computers! We already have storage down, and manipulation would be handled with edit functionality.

We should work on retrieval.

Changes

Current implementations of the note-taking app specifications do search in different ways. Most projects can list the files in a directory. Some of them have manually designed headers to store modification date metadata. Headers are combed when searching, or a backend is built to store a database of changes that are combed. Lastly only search_by_filename requires the exact filename to be known.

Regular Expressions

search_by_filename and search_by_content should support regular expression matching. The user should be able to provide a --re flag and the search term is interpreted as a regular expression.

Fuzzy Matching

search_by_filename and search_by_content should support an optional --fuzzy that does fuzzy matching to the input string.

search_by_content

This function should work similarly to search_by_filename. We should display the number of matches, and then a list. Items of the list should be filenames followed by the lines immediately before, including, immediately after the search match.

@augustus-thomas augustus-thomas added the enhancement New feature or request label Mar 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant