CLI tool to search text in XLSX and XLS files. It works similary to grep
Project description
Owerview
xlsxgrep is a command-line tool to search text in XLSX and XLS files. It works similary to Unix/Linux grep.
Features
-
Grep compatible: xlsxgrep tries to be compatible with Unix/Linux grep, where it makes sense. Some of grep options are supported (such as
-r
,-i
or-c
). -
Search many XLSX and XLS files at once, even recursively in directories.
-
Regular expressions: Python regex.
Usage:
usage: xlsxgrep.py [-h] [-i] [-P] [-w] [-H] [-c] [-N] [-r] [-V]
[-sep SEPARATOR]
pattern path [path ...]
positional arguments:
pattern Use PATTERN as the pattern to search for.
path file or folder location
optional arguments:
-h, --help show this help message and exit
-i, --ignore-case Ignore case distinctions.
-P, --python-regex PATTERN is a Python regular expression.
-w, --word-regexp Force PATTERN to match only whole words.
-H, --with-filename Print the file name for each match.
-c, --count Print only a count of matches per file
-N, --with-sheetname Print the sheet name for each match.
-r, --recursive Search directories recursively.
-V, --version Display version information and exit.
-sep SEPARATOR, --separator SEPARATOR
Define custom list separator for output, default is
TAB
Example
$ xlsxgrep "myPATTERN" --with-filename --with-sheetname -sep=";" Document.xlsx
Document.xlsx: Sheet1: ;column1;column2;myPATTERN;column3;column4;column5;column6
Installation
pip install xlsxgrep
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
xlsxgrep-0.0.22.tar.gz
(3.8 kB
view hashes)
Built Distribution
Close
Hashes for xlsxgrep-0.0.22-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 52e76f9135285111f995252d5b1b8ce5eeca16e57b61f88af472d9ceeceac7ff |
|
MD5 | 0c799a942114663232f8dfaa0b3c622f |
|
BLAKE2b-256 | 47340d39c993ea16bd1a225da633dcd2ceec23c1041cb74ae44aa2ffada54163 |