Hello all,
I'm thinking about doing a software which does a suggestion based file search of linux files. Juz like the google suggest feature, this software should display suggestions dynamically when a character is typed.. Is such a software possible in linux? Can anyone lead me in the right direction as i dont know where to start in this project..Plz help..


Thanks in advance...

Dani AI

Generated

A suggestion-driven file search on Linux is straightforward to build; it just helps to split the problem and pick pragmatic defaults up front. asked whether it’s possible — yes — and was right to flag language choice. Below is a compact, practical roadmap you can apply in any language.

Split the system into three pieces: (1) an indexer that does an initial crawl and keeps a searchable index, (2) an incremental watcher that updates the index (inotify/fanotify), and (3) a query layer that serves quick suggestions to the UI. For the index store use a searchable inverted index (SQLite + FTS for a simple start, or Xapian/Lucene for larger needs). Keep a small in-memory prefix structure (trie or TST) populated with top-N hits for instant suggestions; fall back to the disk index for broader or fuzzy matches.

Make the UI async and layered: debounce keystrokes (200–300 ms), check the in-memory prefix index first, then issue a background query for token/substring matches, and only run fuzzy matching if the user pauses. Rank suggestions by a mix of prefix match score, file recency, frequency (tracked when files are opened), and path depth. Respect permissions (index per-user or obey fs ACLs), exclude virtual filesystems (/proc, /sys, /dev), and avoid symlink loops. Batch index updates and use ionice/nice so background indexing doesn’t kill interactive performance.

Example interaction loop (pseudocode):

on_input(chars):
  debounce(250ms)
  suggestions = inMemoryPrefix.search(chars)
  async fetch diskIndex.layeredSearch(chars) -> merge_and_rank(suggestions)
  display(topN)

Start with a prototype in Python for speed or Go/Rust for a single fast binary. Test on a large tree, watch for missed inotify events (fallback to periodic full rescan), and iterate on ranking heuristics.

Recommended Answers

All 2 Replies

Everything is possible... Well, first you need to choose a programming language, i recommend you to make a reseach and find out what is the most suitable to make a suggestion based file search of linux files. Then get some tutorials, and start building it, if you get stuck use your best friend to help you (Google), if after your research you are still stuck, use a programming forum where you can ask for help, you can use daniweb forum to ask your questions. If I didn't answer your questions, please be more specific.

Dan08

Everything is possible... Well, first you need to choose a programming language, i recommend you to make a reseach and find out what is the most suitable to make a suggestion based file search of linux files. Then get some tutorials, and start building it, if you get stuck use your best friend to help you (Google), if after your research you are still stuck, use a programming forum where you can ask for help, you can use daniweb forum to ask your questions. If I didn't answer your questions, please be more specific.

Dan08

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.