Code Monkey home page Code Monkey logo

xlsxgrep's Introduction

Owerview

xlsxgrep is a CLI tool to search text in XLSX, XLS, CSV, TSV and ODS files. It works similarly to Unix/GNU 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, XLS, CSV, TSV and ODS files at once, even recursively in directories.

  • Regular expressions: Python regex.

  • Supported file types: csv, ods, tsv, xls, xlsx

Usage:


usage: xlsxgrep [-h] [-V] [-P] [-F] [-i] [-w] [-c] [-r] [-H] [-N] [-l] [-L] [-S SEPARATOR] [-Z]
                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
  -V, --version         display version information and exit.
  -P, --python-regex    PATTERN is a Python regular expression. This is the default.
  -F, --fixed-strings   interpret PATTERN as fixed strings, not regular expressions.
  -i, --ignore-case     ignore case distinctions.
  -w, --word-regexp     force PATTERN to match only whole words.
  -c, --count           print only a count of matches per file.
  -r, --recursive       search directories recursively.
  -H, --with-filename   print the file name for each match.
  -N, --with-sheetname  print the sheet name for each match.
  -l, --files-with-match
                        print only names of FILEs with match pattern.
  -L, --files-without-match
                        print only names of FILEs with no match pattern.
  -S SEPARATOR, --separator SEPARATOR
                        define custom list separator for output, the default is TAB
  -Z, --null            output a zero byte (the ASCII NUL character) instead of the usual newline.
 

Examples:

xlsxgrep -i "foo" foobar.xlsx
xlsxgrep -c -H "(?i)foo|bar" /folder

Installation

     pip install xlsxgrep  

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.