Python file indexer in python
I made an app in python ‘file indexer’ , i used Tkinter, that let the user add some tags/description words/keywords to a file , to make…
Python file indexer in python
I made an app in python ‘file indexer’ , i used Tkinter, that let the user add some tags/description words/keywords to a file , to make search easier using these infos , and shows its path , what does the app do is to take a file X , get its paths , and ask the user for the keywords the descriptions and the words, and then create a json file with random name , inside the folder /indexers, the json file contains all these infos that the user added for the file , including the file path , when the app is launched , it shows a splash screen with two buttons , “import files” , and “search files”.
Splash Screen
The “import files” button , all it does is to make the user import the specific file to make an indexer json for , once the file is choosed (make sure the path exists + not None) , it shows a form input for the user to make him add some informations for the indexer , including all informations i described before (for the tag inputs , make the user can add/remove tags ) , (custom file name:text, tags:array , description:text) , the form input is required , if the form has an input that is empty , the app shows an error and closes the form (do not close the splash screen that contains the buttons), once the form is submitted and all inputs are not empty , create a json file (indexer) with a random name , that contains the choosed file path , and the other infos.
Indexer
The indexer in term of this app , is a json file that has a random name , and contains the path of a file , and some other infos that the user choose , to make file search easier , precisely for non organised files.
The json structure of the indexer looks like :
{
"filename": "my file", // custom file name by the user
"filepath": " C:\\...something", // the real path of the file name
"description": "pour le travail", // the description text by the user
"keywords": [ // keywords added by the user
"work",
"essentiels",
"travail"
],
}
Search Process
For the “search button” , it allows the user to search over indexers , in order to find a file by a matching word from its description , a tag , or its custom name. The search process show max possible results , ignoring letter case match , can mark the word found in a description of a file , also the results elements UI would be something like that :

Result of foud indexer that match the keywords
Note that
[ ! ] Every “result component” contains the title wich is the custom file name that the user entered , the path with opacity of 0.4 , the text description with keywords searched highlighted , tags highlighted if matches some words in the search query , two buttons at the end of the ui (top right) , one is ‘Open’ wich open directly the file in the default system specified app for its type , and the other is ‘Open in Explorer’ wich reveals the file path in the file explorer (open just the folder)
[ ! ] The search process took the user input (wich is the text in the search bar) , and split the value of that input , and use it to search matching indexers description (if a word of user input matches a word from file indexer => show it in results) , to show the max results of the matching queries
[ ! ] If the result compo , wich represents the indexer , has the path of a deleted path or moved (generally not exists) , it shows the compo with a red border , and make it disable of the user click , and if the user make a ‘mouse hover’ , shows a little ‘tooltip text’ that indicated “This file doesn’t exists”
메타데이터
- post_id
- d6596aeb321f
- slug
- python-file-indexer-in-python-d6596aeb321f
- url
- https://medium.com/@luciusartiuscastus68/python-file-indexer-in-python-d6596aeb321f
- canonical_url
- https://medium.com/@luciusartiuscastus68/python-file-indexer-in-python-d6596aeb321f
- author_url
- https://medium.com/@luciusartiuscastus68
- status
- ok
- fetched_at
- 2026-06-22 17:31:34