summaryrefslogtreecommitdiffstats
path: root/complete
AgeCommit message (Collapse)Author
2018-09-04ripgrep: add --pre-glob flagAndrew Gallant
The --pre-glob flag is like the --glob flag, except it applies to filtering files through the preprocessor instead of for search. This makes it possible to apply the preprocessor to only a small subset of files, which can greatly reduce the process overhead of using a preprocessor when searching large directories.
2018-09-04ripgrep: add --line-buffered and --block-bufferedAndrew Gallant
These flags provide granular control over ripgrep's buffering strategy. The --line-buffered flag can be genuinely useful in certain types of shell pipelines. The --block-buffered flag has a murkier use case, but we add it for completeness.
2018-08-27complete: don't complete bare pattern after -fdana
2018-08-26ripgrep: add --sort and --sortr flagsAndrew Gallant
These flags each accept one of five choices: none, path, modified, accessed or created. The value indicates how the results are sorted. For --sort, results are sorted in ascending order where as for --sortr, results are sorted in descending order. Closes #404
2018-08-26ignore: add 'same_file_system' optionAndrew Gallant
This commit adds a 'same_file_system' option to the walk builder. For single threaded walking, it defers to the walkdir crate, which has the same option. The bulk of this commit implements this flag for the parallel walker. We add one very feeble test for this. The parallel walker is now officially a complete mess. Closes #321
2018-08-21ripgrep: make --no-pcre2-unicode the canonical flagAndrew Gallant
Previously, we used --pcre2-unicode as the canonical flag despite the fact that it is enabled by default, which is inconsistent with how we handle other similar flags. The reason why --pcre2-unicode was made the canonical flag was to make it easier to discover since it would be sorted near the --pcre2 flag. To solve that problem, we simply start a convention that lists related flags in the docs. Fixes #1022
2018-08-20complete: add completion reference guidedana
2018-08-20ripgrep: add --no-multiline-dotalldana
2018-08-20complete: update wording, exclusion, &c.dana
2018-08-20ripgrep: migrate to libripgrepAndrew Gallant
This commit does the work to delete the old `grep` crate and effectively rewrite most of ripgrep core to use the new libripgrep crates. The new `grep` crate is now a facade that collects the various crates that make up libripgrep. The most complex part of ripgrep core is now arguably the translation between command line parameters and the library options, which is ultimately where we want to be.
2018-07-24complete: add --no-pre, improve --pre/--search-zip exclusivitydana
2018-07-22ripgrep: add --no-ignore-global flagAndrew Gallant
This commit adds a new --no-ignore-global flag that permits disabling the use of global gitignore filtering. Global gitignores are generally found in `$HOME/.config/git/ignore`, but its location can be configured via git's `core.excludesFile` option. Closes #934
2018-07-21ripgrep: add --pre flagCharles Blake
The preprocessor flag accepts a command program and executes this program for every input file that is searched. Instead of searching the file directly, ripgrep will instead search the stdout contents of the program. Closes #978, Closes #981
2018-07-06complete: improve zsh completiondana
- Use groups with _arguments - Conditionally complete 'negation' options (--messages, --no-column, &c.) - Improve option exclusivity - Improve option descriptions - Improve completion of colour 'whens' - Improve completion of colour specs - Remove some unnecessary work-arounds - Use more idiomatic conventions
2018-06-25ripgrep: rename --maxdepth to --max-depthdana
We keep the old `--maxdepth` spelling to preserve backward compatibility. PR #967
2018-04-23output: remove --line-number-width flagAndrew Gallant
This commit does what no software project has ever done before: we've outright removed a flag with no possible way to recapture its functionality. This flag presents numerous problems in that it never really worked well in the first place, and completely falls over when ripgrep uses the --no-heading output format. Well meaning users want ripgrep to fix this by getting into the alignment business by buffering all output, but that is a line that I refuse to cross. Fixes #795
2018-04-23complete: add --no-ignore-messagesAndrew Gallant
2018-03-10output: add --stats flagBalaji Sivaraman
This commit provides basic support for a --stats flag, which will print various aggregate statistics about a search after all of the results have been printed. This is mostly intended to support a similar feature found in the Silver Searcher. Note though that we don't emit the total bytes searched; this is a first pass at an implementation and we can improve upon it later. Closes #411, Closes #799
2018-03-10search: add a --count-matches flagBalaji Sivaraman
This commit introduces a new flag, --count-matches, which will cause ripgrep to report a total count of all matches instead of a count of total lines matched. Closes #566, Closes #814
2018-03-10search: add -b/--byte-offset flagBalaji Sivaraman
This commit adds support for printing 0-based byte offset before each line. We handle corner cases such as `-o/--only-matching` and `-C/--context` as well. Closes #812
2018-02-20termcolor: add underline supportBalaji Sivaraman
This commit adds underline support to the termcolor crate, and exposes it through ripgrep. Fixes #798
2018-02-04config: add persistent configurationAndrew Gallant
This commit adds support for reading configuration files that change ripgrep's default behavior. The format of the configuration file is an "rc" style and is very simple. It is defined by two rules: 1. Every line is a shell argument, after trimming ASCII whitespace. 2. Lines starting with '#' (optionally preceded by any amount of ASCII whitespace) are ignored. ripgrep will look for a single configuration file if and only if the RIPGREP_CONFIG_PATH environment variable is set and is non-empty. ripgrep will parse shell arguments from this file on startup and will behave as if the arguments in this file were prepended to any explicit arguments given to ripgrep on the command line. For example, if your ripgreprc file contained a single line: --smart-case then the following command RIPGREP_CONFIG_PATH=wherever/.ripgreprc rg foo would behave identically to the following command rg --smart-case foo This commit also adds a new flag, --no-config, that when present will suppress any and all support for configuration. This includes any future support for auto-loading configuration files from pre-determined paths (which this commit does not add). Conflicts between configuration files and explicit arguments are handled exactly like conflicts in the same command line invocation. That is, this command: RIPGREP_CONFIG_PATH=wherever/.ripgreprc rg foo --case-sensitive is exactly equivalent to rg --smart-case foo --case-sensitive in which case, the --case-sensitive flag would override the --smart-case flag. Closes #196
2018-01-30search: add support for searching compressed filesBalaji Sivaraman
This commit adds opt-in support for searching compressed files during recursive search. This behavior is only enabled when the `-z/--search-zip` flag is passed to ripgrep. When enabled, a limited set of common compression formats are recognized via file extension, and a new process is spawned to perform the decompression. ripgrep then searches the stdout of that spawned process. Closes #539
2018-01-11printer: add --passthru flagdana
The --passthru flag causes ripgrep to print every line, even if the line does not contain a match. This is a response to the common pattern of `^|foo` to match every line, while still highlighting things like `foo`. Fixes #740
2018-01-01printer: add support for line number alignmentBalaji Sivaraman
Closes #544
2017-09-06doc: clarify --with-filename behavior with --headingDan Fabulich
2017-08-09Add -x/--line-regexp (#520)dana
add -x/--line-regexp flag
2017-07-26Make completion support short-option values in same word; handle debug variabledana
2017-07-18Refactor zsh completion functiondana
- Improve documentation - Reorganise into functions - Order options lexicographically - Correct minor wording inconsistencies - Fix --count error - Fix --maxdepth error - Fix --path-separator error - Fix --version error - Adjust exclusivity for --files, -h, -j, -o, -r, -t, -T, -v, -V, &c. - Improve pattern-operand guard behaviour - Partially fix issue with colorspec state - Fix issue with typespec state - Add completion for <type>:include: sequence - Move licence info out of the way
2017-07-06Add `-f` to completionsdana
2017-07-03Add --iglob to zsh completion functiondana
2017-07-03Improve zsh completion functiondana
- Add missing options - Fix confusion between --count and --max-count - Improve wording consistency (capitalisation, punctuation, contractions, &c.) - Add completion for encodings - Add completion for colour specs - Add partial completion for type specs
2017-05-29Add Zsh completion fileFangrui Song