Skip to content

Files

Latest commit

 

History

History

FileTextSearch

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 

File Text Search Script

Description

The FileTextSearch.py script is a utility designed to search for a specific keyword or phrase within text-based files located in a specified directory. The script searches through files with the following extensions: .txt, .docx, and .pdf. It can recursively search through subdirectories, making it easier to locate documents containing the desired information.

Features

  • Recursive Searching: The script can search within specified subdirectories.
  • Keyword Matching: Users can input a keyword or phrase to find within the text files.
  • Supported Formats: The script can read .txt, .docx, and .pdf file formats.

Usage

  1. Ensure you have Python installed on your machine.
  2. Download the FileTextSearch.py script.
  3. Open a terminal or command prompt and navigate to the directory where the script is located.
  4. Run the script using the following command: python FileTextSearch.py
  5. When prompted, enter the path of the directory you want to search. Enter path: /path/to/your/directory
  6. Enter the keyword or phrase you want to search for in the files. Keyword/Phrase: your_keyword
  7. The script will search through the specified directory and print out the names of any files where the keyword is found.

Requirements

  • Python 3.x
  • Basic understanding of file paths in your operating system.
  • The script will read text-based files, so ensure the files are not encrypted or password protected.

License

This script is open-source and free to use. Feel free to modify and distribute as needed.

Contributing

If you'd like to contribute to this project, please open an issue or submit a pull request with your proposed changes or enhancements.