Code Monkey home page Code Monkey logo

grepp's Introduction

grepp(1)

Name

grepp - An improved version of the most common combinations of grep, find and sed/perl, in a single script.

Synopsys

grepp pattern [location] [-r replace_pattern [-f]] [-I] [-c] [-l] [--ignore-extension|--ie ext] [--color] [--buffer size] [--show-buffer-errors|--sbe] [--no-pager] [--debug|--trace]

grepp [-h |-?] # Short help

grepp [--help] # Extended help

command | grepp [options] 'pattern' # pipe usage

Description

greps 'pattern' recursively from current dir or 'location' in every file except for file patterns given by the cmdline option --ignore-file.

It is inspired in grep, but unlike grep it doesn’t print a : divider right after the file name since that makes it annoying to double click to select, it adds a space before and after the : divider.

As it is expected, the color only shows when the ouput is not being piped. See --color for more details.

It automatically pipes the output to your environment PAGER or to less -R if no environment value is set.

Options

'pattern'

Pattern to grep for (In regex syntax).

'location'

Location to search in. By default it will use the current directory.

-c | --case

Do not ignore case.

-l

Print file name only.

-I

Do not ignore binary files.

TODO --name | --iname 'file_pattern'

filter result to match only things that match 'file_pattern'. iname does case insensitive matching.

TODO --if | --ignore-file 'file_pattern'

Ignore files matching 'file_pattern' regex. Can be used more than once. Case insensitive.

TODO --fullpath

Print full paths for matching files.

TODO --spacing

Print original spacing. By default initial spacing is ignored.

TODO -C 'NUM', -'NUM', --context='NUM'

Print 'NUM' lines of output context. Places a line containing a group separator (--) between contiguous groups of matches. With the -o or --only-matching option, this has no effect and a warning is given.

--color 'never'|'auto'|'always'

Select color use: never, auto (default), always.

Why grep’s ouptut sucks

grep prints a colon : divider after the file name since that makes it annoying to double click to select.

TODO: images here

Roadmap

  • Use Git ignore file.

License

This file is part of grepp.

Copyright © 2012-2017 David Gamba Rios

This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.

grepp's People

Contributors

davidgamba avatar

Watchers

 avatar

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.