/pyfindstr

Fancy way to look up for a text in a file.

MIT LicenseMIT

pyfindstr

pyfindstr is just a simple Python script that looks up for a keyword on any files (or specified by the file type) and recursively.

(You could also say that this is just a fancy way to look up for a string in a file. ¯_( ツ )_/¯)

Usage

You need to have Python (at least version 3.5 or higher) installed first on your system.
Then, it's as simple as this:

  • Open up your command prompt or terminal.
  • Type in python findstry.py

The same can be achieved on Windows by using this command:

findstr /s /i "(keyword)" "(path)"

For example:

findstr /s /i "cdn" "D:\Projects\GitHub\Shiro39\jekyll-mdui\*.html"

This command will look up for the keyword cdn on any .html files in the given path.
Feel free to read more about the findstr command in here.

BUT! this script does NOT use any of the OS' native command. pathlib is the one that does the magic in this script.