commit_hash stringlengths 40 40 | author stringlengths 1 57 | date timestamp[s]date 2010-07-26 04:45:09 2026-04-14 18:21:10 | message stringlengths 8 1.39M | diff stringlengths 68 51.2k | files_changed int64 1 136 | insertions int64 0 2.35k | deletions int64 0 1.9k |
|---|---|---|---|---|---|---|---|
f5ede0e31942825fc1329f7dfbba0c3ef4bb560f | Andrew Gallant | 2017-03-12T20:51:55 | Add scss and ejs.
We add scss to the existing `css` file type and `ejs` to the existing
`html` file type.
Fixes #393 | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index 9649762..6fb97e1 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -116,7 +116,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("crystal", &["Projectfile", "*.cr"]),
("cs", &["*.cs"]),
("csharp", &[... | 1 | 2 | 2 |
6ecffec53700a813d4b0cb192d703341a1641122 | Andrew Gallant | 2017-03-12T20:07:01 | Fix test on Windows.
(This is what I get for directly pushing to master.) | diff --git a/tests/tests.rs b/tests/tests.rs
index d56e495..29848aa 100644
--- a/tests/tests.rs
+++ b/tests/tests.rs
@@ -1054,7 +1054,7 @@ clean!(regression_405, "test", ".", |wd: WorkDir, mut cmd: Command| {
cmd.arg("-g").arg("!/foo/**");
let lines: String = wd.stdout(&mut cmd);
- assert_eq!(lines, "bar... | 1 | 1 | 1 |
80e91a1f1d725eb8e331f3613a352edb8b13677b | Andrew Gallant | 2017-03-12T19:51:07 | Fix leading slash bug when used with `!`.
When writing paths like `!/foo` in gitignore files (or when using the
-g/--glob flag), the presence of `!` would prevent the gitignore builder
from noticing the leading slash, which causes absolute path matching to
fail.
Fixes #405 | diff --git a/ignore/src/gitignore.rs b/ignore/src/gitignore.rs
index 7e547c2..4972dcd 100644
--- a/ignore/src/gitignore.rs
+++ b/ignore/src/gitignore.rs
@@ -368,9 +368,10 @@ impl GitignoreBuilder {
};
let mut literal_separator = false;
let has_slash = line.chars().any(|c| c == '/');
- ... | 3 | 22 | 1 |
7c37065911d9f23bfbeb51f0cb635719b796ccbe | Andrew Gallant | 2017-03-09T01:23:12 | update deps | diff --git a/Cargo.lock b/Cargo.lock
index 99c3f0e..16ae133 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -5,15 +5,15 @@ dependencies = [
"atty 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
"bytecount 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"clap 2.20.5 (registry+https://gi... | 1 | 41 | 41 |
33ec988d7068e0d7a6d6504bcf3a06056344e887 | Marc Tiehuis | 2017-03-01T05:48:06 | Remove regex build-dependency in Cargo.toml | diff --git a/Cargo.toml b/Cargo.toml
index bac7e3f..2a07929 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -45,7 +45,6 @@ termcolor = { version = "0.3.0", path = "termcolor" }
[build-dependencies]
clap = "2.18"
lazy_static = "0.2"
-regex = "0.2.1"
[features]
avx-accel = ["bytecount/avx-accel"] | 1 | 0 | 1 |
adff43fbb4ce7b0663759d445a944286583acaf4 | Marc Tiehuis | 2017-03-01T05:38:06 | Remove clap validator + add max-filesize integration tests | diff --git a/build.rs b/build.rs
index 4d0e2d1..8a7c490 100644
--- a/build.rs
+++ b/build.rs
@@ -2,7 +2,6 @@
extern crate clap;
#[macro_use]
extern crate lazy_static;
-extern crate regex;
use std::env;
use std::fs;
diff --git a/src/app.rs b/src/app.rs
index 6d5177c..e2f4b01 100644
--- a/src/app.rs
+++ b/src/app.... | 5 | 60 | 34 |
71585f6d476265338e9ee4e924b4f43b02f2d233 | Marc Tiehuis | 2017-03-01T05:01:46 | Reduce unnecessary stat calls for max_filesize | diff --git a/ignore/src/walk.rs b/ignore/src/walk.rs
index 37d05ed..a5989d1 100644
--- a/ignore/src/walk.rs
+++ b/ignore/src/walk.rs
@@ -682,9 +682,16 @@ impl Walk {
return false;
}
- let ft = ent.file_type().is_dir();
- skip_path(&self.ig, ent.path(), ft) ||
- skip_filesize... | 1 | 31 | 23 |
49fd6687120ef11192847ef47191bbc6d32a2ed9 | tiehuis | 2017-02-25T22:36:59 | Add file size exclusion to walker
A maximum filesize can be specified as an argument to a `WalkBuilder`.
If a file exceeds the specified size it will be ignored as part of the
resulting file/directory set.
The filesize limit never applies to directories. | diff --git a/ignore/src/walk.rs b/ignore/src/walk.rs
index 860f26d..37d05ed 100644
--- a/ignore/src/walk.rs
+++ b/ignore/src/walk.rs
@@ -392,7 +392,9 @@ impl DirEntryRaw {
/// continues.
/// * Fifth, if the path hasn't been whitelisted and it is hidden, then the
/// path is skipped.
-/// * Sixth, if the path has mad... | 1 | 87 | 3 |
066f97d85553f12696272086d26fa86fc2c84d9e | Marc Tiehuis | 2017-03-04T08:40:19 | Add enclosing group to alternations in globs
Fixes #391. | diff --git a/globset/src/glob.rs b/globset/src/glob.rs
index 42d651f..fbfc7d9 100644
--- a/globset/src/glob.rs
+++ b/globset/src/glob.rs
@@ -659,9 +659,18 @@ impl Tokens {
for pat in patterns {
let mut altre = String::new();
self.tokens_to_regex(opt... | 2 | 32 | 2 |
4e8c0fc4ade785775005b416dc030295c684cb67 | Andrew Gallant | 2017-02-25T23:43:13 | bump clap to 2.20.5
Fixes #383 | diff --git a/Cargo.lock b/Cargo.lock
index a9c5892..99c3f0e 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -5,7 +5,7 @@ dependencies = [
"atty 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
"bytecount 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"clap 2.20.5 (registry+https://gith... | 2 | 4 | 4 |
da1764dfd1da683788788cc9e64e704095400179 | Igor Gnatenko | 2017-02-25T21:56:17 | update env_logger to 0.4 | diff --git a/Cargo.toml b/Cargo.toml
index 308edc1..82efb04 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -29,7 +29,7 @@ path = "tests/tests.rs"
atty = "0.2.2"
bytecount = "0.1.4"
clap = "2.19.0"
-env_logger = { version = "0.3", default-features = false }
+env_logger = { version = "0.4", default-features = false }
gr... | 1 | 1 | 1 |
796eaab0d745d8abacf0568a9673450391636e75 | deepy | 2017-02-23T15:35:08 | Add .log as FileType | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index 4c0c72f..9649762 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -145,6 +145,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("kotlin", &["*.kt", "*.kts"]),
("less", &["*.less"]),
("lisp", &["*.el... | 1 | 1 | 0 |
79d40d0e20a5710476b43c58c42db5124c2010a1 | Andrew Gallant | 2017-02-18T21:20:21 | Tweak how binary files are handled internally.
This commit fixes two issues. The first issue is that if a file contained
many NUL bytes without any LF bytes, then the InputBuffer would read the
entire file into memory. This is not typically a problem, but if you run
rg on /proc, then bad things can happen when reading... | diff --git a/src/search_buffer.rs b/src/search_buffer.rs
index 2b792b5..4745c2f 100644
--- a/src/search_buffer.rs
+++ b/src/search_buffer.rs
@@ -113,8 +113,8 @@ impl<'a, W: WriteColor> BufferSearcher<'a, W> {
#[inline(never)]
pub fn run(mut self) -> u64 {
- let binary_upto = cmp::min(4096, self.buf.l... | 2 | 24 | 17 |
525b27804949d9362d4e1890a0cfa18a2eb272bd | Andrew Gallant | 2017-02-18T20:34:54 | Don't parses regexes with --files.
When the --files flag is given, ripgrep would still try to parse some of
the positional arguments as regexes. Don't do that.
Fixes #326 | diff --git a/src/args.rs b/src/args.rs
index 68b8ca0..a968617 100644
--- a/src/args.rs
+++ b/src/args.rs
@@ -434,6 +434,9 @@ impl<'a> ArgMatches<'a> {
///
/// If any pattern is invalid UTF-8, then an error is returned.
fn patterns(&self) -> Result<Vec<String>> {
+ if self.is_present("files") || se... | 1 | 3 | 0 |
16de47920cb14d03a1ed5d851a9f5283472d3d7c | Andrew Gallant | 2017-02-18T20:25:08 | Permit --heading to override --no-heading.
@kbknapp <3
Fixes #327 | diff --git a/src/app.rs b/src/app.rs
index e8ceeb5..9ead9c5 100644
--- a/src/app.rs
+++ b/src/app.rs
@@ -135,8 +135,8 @@ fn app<F>(next_line_help: bool, doc: F) -> App<'static, 'static>
.arg(flag("files-without-match"))
.arg(flag("with-filename").short("H"))
.arg(flag("no-filename"))
- ... | 1 | 2 | 2 |
a114b860635c98198d53e6ba8ed37c88df2c5cc3 | Andrew Gallant | 2017-02-18T20:09:25 | update termcolor dep | diff --git a/Cargo.lock b/Cargo.lock
index dccf829..a9c5892 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -4,11 +4,10 @@ version = "0.4.0"
dependencies = [
"atty 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
"bytecount 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "clap 2.19.3 (... | 2 | 23 | 26 |
a5a16ebb27aa5426de0f95849c731d2b92ba1496 | Andrew Gallant | 2017-02-18T20:07:43 | termcolor-0.3.0 | diff --git a/termcolor/Cargo.toml b/termcolor/Cargo.toml
index 0c23647..f777ea4 100644
--- a/termcolor/Cargo.toml
+++ b/termcolor/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "termcolor"
-version = "0.2.0" #:version
+version = "0.3.0" #:version
authors = ["Andrew Gallant <jamslam@gmail.com>"]
description = """
A ... | 1 | 1 | 1 |
8ac5bc0147b1e75d82cd7038ae07e296a272285e | Andrew Gallant | 2017-02-18T20:05:47 | Remove Windows deps from ripgrep proper.
All Windows specific code has been (mostly) pushed out of ripgrep and
into its constituent libraries. | diff --git a/Cargo.toml b/Cargo.toml
index d732663..6773ba7 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -42,10 +42,6 @@ regex = "0.2.1"
same-file = "0.1.1"
termcolor = { version = "0.2.0", path = "termcolor" }
-[target.'cfg(windows)'.dependencies]
-kernel32-sys = "0.2.2"
-winapi = "0.2.8"
-
[build-dependencies]
c... | 2 | 0 | 8 |
cf750a190fcea9cabe16cd1bef4b21f62929a370 | Stu Hood | 2017-01-23T02:15:26 | Implement Hash for Glob, and re-implement PartialEq using only non-redundant fields. | diff --git a/globset/src/glob.rs b/globset/src/glob.rs
index 514e2ed..42d651f 100644
--- a/globset/src/glob.rs
+++ b/globset/src/glob.rs
@@ -1,5 +1,6 @@
use std::ffi::{OsStr, OsString};
use std::fmt;
+use std::hash;
use std::iter;
use std::ops::{Deref, DerefMut};
use std::path::{Path, is_separator};
@@ -76,7 +77,7... | 1 | 16 | 2 |
d825648b8624ee83a066230e4551d69767477d36 | Andrew Gallant | 2017-02-12T20:37:50 | Remove lazy_static from globset | diff --git a/Cargo.lock b/Cargo.lock
index b0d1375..dccf829 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -106,7 +106,6 @@ version = "0.1.3"
dependencies = [
"aho-corasick 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)",
"fnv 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)",
- "lazy_stat... | 3 | 0 | 4 |
e424f874872d05ef60d8eb9565806ed64815b3b5 | Ahmed El Gabri | 2017-02-09T11:32:08 | Add .twig as a Filetype | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index 856163b..4c0c72f 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -186,6 +186,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("ts", &["*.ts", "*.tsx"]),
("txt", &["*.txt"]),
("toml", &["*.toml", "... | 1 | 1 | 0 |
f5b2c96b778b7ce28bd8ee7e2d277694ba1f123c | Samuel Colvin | 2017-01-30T21:35:30 | add '*.sass' to sass type | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index d85f344..856163b 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -170,7 +170,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("rst", &["*.rst"]),
("ruby", &["Gemfile", "*.gemspec", ".irbrc", "Rakefile"... | 1 | 1 | 1 |
6e209b6fdbd8e3f062793f946cc7b55c2ed958f2 | Daniel Hahler | 2017-01-29T15:30:56 | Look for global git/ignore in ~/.config/git, not ~/git
The documentation says:
> If `$XDG_CONFIG_HOME` is not set or is empty, then
> `$HOME/.config/git/ignore` is used instead.
This is the expected behavior, but the code looked at ~/git/ignore
instead. | diff --git a/ignore/src/gitignore.rs b/ignore/src/gitignore.rs
index 6a0bc96..7e547c2 100644
--- a/ignore/src/gitignore.rs
+++ b/ignore/src/gitignore.rs
@@ -454,7 +454,7 @@ fn gitconfig_contents() -> Option<Vec<u8>> {
fn excludes_file_default() -> Option<PathBuf> {
env::var_os("XDG_CONFIG_HOME")
.and_the... | 1 | 1 | 1 |
72e3c54e0af539c3c6b6d7b872a295884c7e97bd | Alexander Altman | 2017-01-24T04:40:09 | Add Ceylon file type filtering | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index bd8e855..d85f344 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -103,6 +103,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("awk", &["*.awk"]),
("c", &["*.c", "*.h", "*.H"]),
("cbor", &["*.cbor"... | 1 | 1 | 0 |
b67886264f5cd9752b4c7c592601129ea85bd3d5 | Andrew Gallant | 2017-01-21T16:31:09 | Add 'text-processing' category. | diff --git a/Cargo.toml b/Cargo.toml
index 8962657..d732663 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -11,7 +11,7 @@ homepage = "https://github.com/BurntSushi/ripgrep"
repository = "https://github.com/BurntSushi/ripgrep"
readme = "README.md"
keywords = ["regex", "grep", "egrep", "search", "pattern"]
-categories = ... | 1 | 1 | 1 |
e67ab459d31da5f294ae6e91467a4d41e6c7c153 | Jake Goulding | 2017-01-20T19:20:28 | Add categories to Cargo.toml | diff --git a/Cargo.toml b/Cargo.toml
index da1c9d2..8962657 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -11,6 +11,7 @@ homepage = "https://github.com/BurntSushi/ripgrep"
repository = "https://github.com/BurntSushi/ripgrep"
readme = "README.md"
keywords = ["regex", "grep", "egrep", "search", "pattern"]
+categories = ... | 1 | 1 | 0 |
de55d37beaff58e02703530df96479af716b78f4 | robi-wan | 2017-01-18T20:58:11 | File Types: Add .eex under Elixir
.eex is the default file ending for templates using Elixir's template engine EEx. | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index dfcf5cf..bd8e855 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -120,7 +120,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("dart", &["*.dart"]),
("d", &["*.d"]),
("elisp", &["*.el"]),
- ("el... | 1 | 1 | 1 |
fecef10c1c0a26f2e855c2959af8426a8cd8015f | Andrew Gallant | 2017-01-18T00:36:23 | update deps | diff --git a/Cargo.lock b/Cargo.lock
index b768d50..b0d1375 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -10,7 +10,7 @@ dependencies = [
"ignore 0.1.7",
"kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
"lazy_static 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc... | 1 | 14 | 14 |
79e5e6671f3f71e5c93d37bd3b53a8e8597ba1fc | Andrew Gallant | 2017-01-18T00:34:48 | wincolor-0.1.2 | diff --git a/wincolor/Cargo.toml b/wincolor/Cargo.toml
index 7ad7b99..c716bad 100644
--- a/wincolor/Cargo.toml
+++ b/wincolor/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "wincolor"
-version = "0.1.1" #:version
+version = "0.1.2" #:version
authors = ["Andrew Gallant <jamslam@gmail.com>"]
description = """
A simpl... | 1 | 1 | 1 |
e573ab5c609194c4610bf27cc85302450a170d67 | Peter Williams | 2017-01-15T20:36:00 | Add stderr support to wincolor. | diff --git a/wincolor/src/win.rs b/wincolor/src/win.rs
index 09de3eb..e61240b 100644
--- a/wincolor/src/win.rs
+++ b/wincolor/src/win.rs
@@ -3,7 +3,7 @@ use std::mem;
use kernel32;
use winapi::{DWORD, HANDLE, WORD};
-use winapi::winbase::STD_OUTPUT_HANDLE;
+use winapi::winbase::{STD_ERROR_HANDLE, STD_OUTPUT_HANDLE}... | 1 | 18 | 6 |
f5a2d022ecd16dfe67ea829267e9220136f20167 | Andrew Gallant | 2017-01-15T21:32:30 | Replace internal atty module with atty crate.
This removes all use of explicit unsafe in ripgrep proper except for
one: accessing the contents of a memory map. (Which may never go away.) | diff --git a/Cargo.lock b/Cargo.lock
index 703b8c8..b768d50 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -2,6 +2,7 @@
name = "ripgrep"
version = "0.4.0"
dependencies = [
+ "atty 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
"bytecount 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",... | 5 | 41 | 152 |
ed60ec736cabab43725ae24e442a407bb0455590 | Andrew Gallant | 2017-01-14T03:09:43 | Fix invalid UTF-8 output on Windows.
Currently, Rust's standard library will yield an error if one tries to
write invalid UTF-8 to a Windows console. This is problematic for
ripgrep when it tries to print matched lines that contain invalid UTF-8.
We work around this by modifying the `termcolor` library to lossily
deco... | diff --git a/termcolor/src/lib.rs b/termcolor/src/lib.rs
index b90bb27..7be64cc 100644
--- a/termcolor/src/lib.rs
+++ b/termcolor/src/lib.rs
@@ -187,7 +187,7 @@ impl ColorChoice {
/// Satisfies `io::Write` and `WriteColor`, and supports optional coloring
/// to stdout.
pub struct Stdout {
- wtr: WriterInner<'stat... | 1 | 114 | 13 |
a7ca2d65632264b2d2f2f50b72dcff58223e5b27 | Andrew Gallant | 2017-01-14T01:01:06 | update same-file dep | diff --git a/Cargo.lock b/Cargo.lock
index c1567e3..3d93bbb 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -15,7 +15,7 @@ dependencies = [
"memmap 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
"num_cpus 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
"regex 0.2.1 (registry+https://g... | 1 | 4 | 4 |
a7d0e4066870178f8529382fe273ce1ce580741d | Andrew Gallant | 2017-01-14T00:02:55 | Use basic SGR sequences when possible.
In Emacs, its terminal apparently doesn't support "extended" sets of
foreground/background colors. Unless we need to set an "intense" color,
we should instead use one of the eight basic color codes.
Also, remove the "intense" setting from the default set of colors. It
doesn't do... | diff --git a/src/args.rs b/src/args.rs
index 6030964..eeccb18 100644
--- a/src/args.rs
+++ b/src/args.rs
@@ -707,7 +707,6 @@ impl<'a> ArgMatches<'a> {
"path:fg:magenta".parse().unwrap(),
"line:fg:green".parse().unwrap(),
"match:fg:red".parse().unwrap(),
- "match:style:i... | 2 | 30 | 22 |
c3de1f58ea45fec442da21e9e1174e4269f64998 | Andrew Gallant | 2017-01-11T02:13:40 | another bytecount update, weird | diff --git a/Cargo.lock b/Cargo.lock
index a84598b..c1567e3 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -314,7 +314,7 @@ dependencies = [
"checksum aho-corasick 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)" = "4f660b942762979b56c9f07b4b36bb559776fbad102f05d6771e1b629e8fd5bf"
"checksum ansi_term 0.9.0... | 1 | 1 | 1 |
e940bc956dcb9bc7ee01bdfea11275d1950d74f5 | Andrew Gallant | 2017-01-10T23:28:39 | update bytecount
Fixes #313 | diff --git a/Cargo.lock b/Cargo.lock
index d3e9bcf..a84598b 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -2,7 +2,7 @@
name = "ripgrep"
version = "0.3.2"
dependencies = [
- "bytecount 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
+ "bytecount 0.1.6 (registry+https://github.com/rust-lang/crates.io-ind... | 1 | 2 | 2 |
461e0c4e33b38532545af4f97ec92bd367963017 | Andrew Gallant | 2017-01-08T15:27:30 | Don't search stdout redirected file.
When running ripgrep like this:
rg foo > output
we must be careful not to search `output` since ripgrep is actively writing
to it. Searching it can cause massive blowups where the file grows without
bound.
While this is conceptually easy to fix (check the inode of the redire... | diff --git a/Cargo.lock b/Cargo.lock
index 3fcef67..d3e9bcf 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -2,19 +2,20 @@
name = "ripgrep"
version = "0.3.2"
dependencies = [
- "bytecount 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
+ "bytecount 0.1.5 (registry+https://github.com/rust-lang/crates.io-i... | 7 | 241 | 69 |
82df3b768587e2839db849e6eed2db518a728778 | chocolateboy | 2017-01-09T18:54:10 | add Kotlin type: "*.kt", "*.kts"
https://en.wikipedia.org/wiki/Kotlin_(programming_language)
https://github.com/udalov/kotlin-vim/blob/master/ftdetect/kotlin.vim | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index 00cf515..dfcf5cf 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -141,6 +141,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
]),
("json", &["*.json"]),
("jsonl", &["*.jsonl"]),
+ ("kotlin", &["... | 1 | 1 | 0 |
ece60111643bbbe3b39178c34a8b3e90227d7ac4 | chocolateboy | 2017-01-09T18:50:22 | Ruby type: add "Gemfile", "*.gemspec", ".irbrc", "Rakefile"
https://github.com/vim-ruby/vim-ruby/blob/master/ftdetect/ruby.vim | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index 91404e5..00cf515 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -166,7 +166,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("r", &["*.R", "*.r", "*.Rmd", "*.Rnw"]),
("rdoc", &["*.rdoc"]),
("rst"... | 1 | 1 | 1 |
00033e1875a8cd0a4429b9393b7bf080c956677a | chocolateboy | 2017-01-09T18:49:50 | Perl type: add "*.t"
https://github.com/petdance/ack2/blob/2.15_02/ConfigDefault.pm#L155 | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index 92b0bf7..91404e5 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -156,7 +156,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("objcpp", &["*.h", "*.mm"]),
("ocaml", &["*.ml", "*.mli", "*.mll", "*.mly"]... | 1 | 1 | 1 |
5aea517fb4849016c8b2ae4acbd680315c0d7a0d | chocolateboy | 2017-01-09T18:49:11 | add Crystal type: "Projectfile", "*.cr"
https://en.wikipedia.org/wiki/Crystal_(programming_language)
https://github.com/rhysd/vim-crystal/blob/master/ftdetect/crystal.vim | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index 213f1df..92b0bf7 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -112,6 +112,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
"*.C", "*.cc", "*.cpp", "*.cxx",
"*.h", "*.H", "*.hh", "*.hpp",
... | 1 | 1 | 0 |
c4633ff187ca29ed1fb179b9ed0768461c121866 | Daniel Luz | 2017-01-08T21:04:38 | Remove trivial condition. | diff --git a/src/search_stream.rs b/src/search_stream.rs
index a736629..1630292 100644
--- a/src/search_stream.rs
+++ b/src/search_stream.rs
@@ -307,7 +307,7 @@ impl<'a, R: io::Read, W: WriteColor> Searcher<'a, R, W> {
} else if self.opts.files_with_matches {
self.printer.path(self.path);
... | 1 | 1 | 1 |
97e6873b38ad58de62f66fc3796b6b82876f1d79 | Andrew Gallant | 2017-01-08T03:50:38 | Fix type compose test. | diff --git a/tests/tests.rs b/tests/tests.rs
index fa02406..11a7604 100644
--- a/tests/tests.rs
+++ b/tests/tests.rs
@@ -316,7 +316,7 @@ sherlock!(file_type_add_compose, "Sherlock", ".", |wd: WorkDir, mut cmd: Command
cmd.arg("--type-add").arg("combo:include:wat,py").arg("-t").arg("combo");
let lines: String ... | 1 | 1 | 1 |
851799f42be4409d4e2498960725e11d0514a0e7 | Andrew Gallant | 2017-01-07T03:44:25 | Fix spacing issue in --help output. | diff --git a/src/app.rs b/src/app.rs
index 8cbb257..d262e5d 100644
--- a/src/app.rs
+++ b/src/app.rs
@@ -238,7 +238,7 @@ lazy_static! {
This flag may be provided multiple times. Settings are applied \
iteratively. Colors are limited to one of eight choices: \
red, blue, gree... | 1 | 1 | 1 |
95cea77625f978a21b1d923e54d13f9217f0ef30 | Andrew Gallant | 2017-01-07T02:43:46 | Tweak the parallel directory iterator.
This commit fixes two issues.
First, the iterator was executing the callback for every child of a
directory in a single thread. Therefore, if the walker was run over a
single directory, then no parallelism is used. We tweak the iterator
slightly so that we don't fall into this t... | diff --git a/ignore/src/walk.rs b/ignore/src/walk.rs
index 938cf46..f0c042c 100644
--- a/ignore/src/walk.rs
+++ b/ignore/src/walk.rs
@@ -6,6 +6,7 @@ use std::path::{Path, PathBuf};
use std::sync::Arc;
use std::sync::atomic::{AtomicBool, AtomicUsize, Ordering};
use std::thread;
+use std::time::Duration;
use std::vec... | 1 | 18 | 16 |
f7a2fe30d4f0fe055e63a630c940383a1d63d6a9 | Jason Shirk (POWERSHELL) | 2017-01-05T00:01:18 | Add powershell as a known file type | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index 23ef47e..1f03258 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -142,6 +142,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("pdf", &["*.pdf"]),
("php", &["*.php", "*.php3", "*.php4", "*.php5", "*.pht... | 1 | 1 | 0 |
aed315e80a34edfa296120228aa6dc5c7616e64d | Andrew Gallant | 2017-01-03T12:27:51 | bump deps | diff --git a/Cargo.lock b/Cargo.lock
index 2c776e4..3fcef67 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -14,17 +14,17 @@ dependencies = [
"memchr 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"memmap 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
"num_cpus 1.2.0 (registry+https:... | 2 | 12 | 21 |
932875684ea181cff8ba6a9a7e1cd5fd004fed35 | Matěj Cepl | 2016-12-30T02:01:10 | Add types for handling SWIG files. (#297)
SWIG from http://swig.org/
Fixes #296 | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index 3dbe6af..23ef47e 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -157,6 +157,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("sql", &["*.sql"]),
("sv", &["*.v", "*.vg", "*.sv", "*.svh", "*.h"]),
... | 1 | 1 | 0 |
b65bb37b14655e1a89c7cd19c8b011ef3e312791 | Andrew Gallant | 2016-12-27T20:46:40 | Remove superfluous memmap dependency in `grep` crate.
Fixes #295. | diff --git a/Cargo.lock b/Cargo.lock
index 657f430..672229d 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -107,7 +107,6 @@ version = "0.1.4"
dependencies = [
"log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
"memchr 0.1.11 (registry+https://github.com/rust-lang/crates.io-index)",
- "memmap 0.5.0 (... | 2 | 0 | 2 |
de5cb7d22e00c18dfce082a68b0cf45924b56e7f | Andrew Gallant | 2016-12-24T17:53:09 | Remove special ^C handling.
This means that ripgrep will no longer try to reset your colors in your
terminal if you kill it while searching. This could result in messing up
the colors in your terminal, and the fix is to simply run some other
command that resets them for you. For example:
$ echo -ne "\033[0m"
The... | diff --git a/Cargo.lock b/Cargo.lock
index 9f6ee78..657f430 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -4,7 +4,6 @@ version = "0.3.2"
dependencies = [
"bytecount 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
"clap 2.19.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "ctrlc 2.0.1 (r... | 4 | 64 | 71 |
7a682f465e74d31ade4cb96c8d32110d33deebd7 | Andrew Gallant | 2016-12-24T15:49:43 | add docs to wincolor | diff --git a/wincolor/src/win.rs b/wincolor/src/win.rs
index 9c3cf76..09de3eb 100644
--- a/wincolor/src/win.rs
+++ b/wincolor/src/win.rs
@@ -142,6 +142,7 @@ impl TextAttributes {
}
/// Whether to use intense colors or not.
+#[allow(missing_docs)]
#[derive(Clone, Copy, Debug, Eq, PartialEq)]
pub enum Intense {
... | 1 | 2 | 0 |
084d3f4911695df94bdc28bd55ae0b8aa290d175 | Andrew Gallant | 2016-12-24T15:06:37 | Small code cleanups. | diff --git a/ignore/src/lib.rs b/ignore/src/lib.rs
index 626588d..c93a4de 100644
--- a/ignore/src/lib.rs
+++ b/ignore/src/lib.rs
@@ -44,6 +44,8 @@ for result in WalkBuilder::new("./").hidden(false).build() {
See the documentation for `WalkBuilder` for many other options.
*/
+#![deny(missing_docs)]
+
extern crate c... | 5 | 32 | 23 |
9911cd0cd9569ef03255b5f1565d781a16d1cd9c | Andrew Gallant | 2016-12-24T14:58:15 | Remove ~ dependency on clap.
The point of the ~ dependency was to avoid implicitly increasing the
minimum Rust version required to compile ripgrep. However, clap's policy
is to support at least two prior releases of Rust (which roughly
corresponds to the convention that others use too), and that is probably
good enoug... | diff --git a/Cargo.toml b/Cargo.toml
index 1043d08..a2bd2c5 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -26,7 +26,7 @@ path = "tests/tests.rs"
[dependencies]
bytecount = "0.1.4"
-clap = "~2.19.0"
+clap = "2.19.0"
ctrlc = "2.0"
env_logger = "0.3"
grep = { version = "0.1.4", path = "grep" } | 1 | 1 | 1 |
82ceb818f3d8745c00c818e7cfe9598cdaa33254 | Andrew Gallant | 2016-12-24T13:32:32 | update deps | diff --git a/Cargo.lock b/Cargo.lock
index 4f4a028..9f6ee78 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -57,7 +57,7 @@ dependencies = [
"strsim 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)",
"term_size 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
"unicode-segmentation 0.1.3 (re... | 1 | 3 | 3 |
dd5ded2f78145755208043db1027cdb85ac9fd5a | Leonardo Yvens | 2016-12-23T19:53:35 | fix some clippy lints (#288) | diff --git a/src/args.rs b/src/args.rs
index 77421c4..b999d49 100644
--- a/src/args.rs
+++ b/src/args.rs
@@ -26,7 +26,7 @@ use worker::{Worker, WorkerBuilder};
use {Result, version};
-/// Args are transformed/normalized from ArgMatches.
+/// `Args` are transformed/normalized from `ArgMatches`.
#[derive(Debug)]
p... | 7 | 21 | 21 |
cbacf4f19ea3a73f04070d942b217b333cf88e67 | Lilian Anatolie Moraru | 2016-12-23T11:47:55 | Update Cargo.lock to bring in clap 2.19.2 fix for ZSH completions. (#287) | diff --git a/Cargo.lock b/Cargo.lock
index d07415f..4f4a028 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -3,7 +3,7 @@ name = "ripgrep"
version = "0.3.2"
dependencies = [
"bytecount 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
- "clap 2.19.1 (registry+https://github.com/rust-lang/crates.io-index)",... | 1 | 3 | 3 |
652c70f207ccfd859055c0bde09cbd6cc4a3d263 | Andrew Gallant | 2016-12-12T11:58:33 | Fix cut-off line in globset docs.
Fixes #277 | diff --git a/globset/src/lib.rs b/globset/src/lib.rs
index c8bc054..3210c58 100644
--- a/globset/src/lib.rs
+++ b/globset/src/lib.rs
@@ -14,8 +14,6 @@ src/**/foo.rs
and a path `src/bar/baz/foo.rs`, then the set would report the first and third
globs as matching.
-Single glob matching is also provided and is done by... | 1 | 0 | 2 |
bb70f967437279e49fb87df23ae567c276e4cc33 | Andrew Gallant | 2016-12-12T11:55:49 | Fix a non-termination bug.
This was a very silly bug. Instead of creating a particular atomic once
and cloning it, we created a new value for each worker.
Fixes #279 | diff --git a/ignore/src/walk.rs b/ignore/src/walk.rs
index 70846dc..938cf46 100644
--- a/ignore/src/walk.rs
+++ b/ignore/src/walk.rs
@@ -767,12 +767,13 @@ impl WalkParallel {
// Create the workers and then wait for them to finish.
let num_waiting = Arc::new(AtomicUsize::new(0));
let num_quitt... | 2 | 11 | 1 |
d66812102b6184a0dd7d168a3afe2dbf209841cb | Andrew Gallant | 2016-12-06T22:29:34 | Fix leading hypen bug by updating clap.
Fixes #270 | diff --git a/Cargo.lock b/Cargo.lock
index 54c420d..1b28c97 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -3,7 +3,7 @@ name = "ripgrep"
version = "0.3.1"
dependencies = [
"bytecount 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
- "clap 2.18.0 (registry+https://github.com/rust-lang/crates.io-index)",... | 4 | 18 | 5 |
86f8c3c8183a67ad3f4ced334b2d05373c76e985 | Andrew Gallant | 2016-12-06T01:15:45 | update Cargo.lock | diff --git a/Cargo.lock b/Cargo.lock
index 633d80b..54c420d 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -7,7 +7,7 @@ dependencies = [
"ctrlc 2.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"env_logger 0.3.5 (registry+https://github.com/rust-lang/crates.io-index)",
"grep 0.1.4",
- "ignore 0.1.5",
+... | 1 | 2 | 2 |
20bcb8d8839388584d3fe873bf93b83cb9a0d041 | Andrew Gallant | 2016-12-06T01:11:48 | ignore-0.1.6 | diff --git a/ignore/Cargo.toml b/ignore/Cargo.toml
index 152a895..b1d36b4 100644
--- a/ignore/Cargo.toml
+++ b/ignore/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "ignore"
-version = "0.1.5" #:version
+version = "0.1.6" #:version
authors = ["Andrew Gallant <jamslam@gmail.com>"]
description = """
A fast library fo... | 1 | 1 | 1 |
7282706b4265317e762a5c77ee3ff3afd5baf9f5 | Andrew Gallant | 2016-12-06T01:05:57 | Fix bug reading root symlink.
When give an explicit file path on the command line like `foo` where `foo`
is a symlink, ripgrep should follow it even if `-L` isn't set. This is
consistent with the behavior of `foo/`.
Fixes #256 | diff --git a/Cargo.lock b/Cargo.lock
index 65fd65f..633d80b 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -10,11 +10,11 @@ dependencies = [
"ignore 0.1.5",
"kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
"lazy_static 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "li... | 3 | 48 | 37 |
160f04894fea3fe47d1ce6231102aa52085bb4ef | Andrew Gallant | 2016-12-04T17:00:13 | Simplify code.
Instead of `Ok(n) if n == 0` we can just write `Ok(0)`. | diff --git a/src/main.rs b/src/main.rs
index 2bf1cf0..1ccbdb3 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -64,7 +64,7 @@ pub type Result<T> = result::Result<T, Box<Error + Send + Sync>>;
fn main() {
match Args::parse().map(Arc::new).and_then(run) {
- Ok(count) if count == 0 => process::exit(1),
+ ... | 1 | 1 | 1 |
0473df1ef5721143941fb7f883e22b17292b35bb | Andrew Gallant | 2016-11-28T23:31:58 | Disable Unicode mode for literal regex.
When ripgrep detects a literal, it emits them as raw hex escaped byte
sequences to Regex::new. This permits literal optimizations for arbitrary
byte sequences (i.e., possibly invalid UTF-8). The problem is that
Regex::new interprets hex escaped byte sequences as *Unicode codepoi... | diff --git a/grep/src/literals.rs b/grep/src/literals.rs
index d931f13..3e68d24 100644
--- a/grep/src/literals.rs
+++ b/grep/src/literals.rs
@@ -79,12 +79,12 @@ impl LiteralSets {
debug!("required literals found: {:?}", req_lits);
let alts: Vec<String> =
req_lits.into_iter().m... | 3 | 12 | 4 |
301a3fd71d3a923419d6d3e7604979b314121801 | Andrew Gallant | 2016-11-28T22:57:26 | Detect more uppercase literals for --smart-case.
This changes the uppercase literal detection for the "smart case"
functionality. In particular, a character class is considered to have an
uppercase literal if at least one of its ranges starts or stops with an
uppercase literal.
Fixes #229 | diff --git a/grep/src/search.rs b/grep/src/search.rs
index 4e4c48e..850c8d6 100644
--- a/grep/src/search.rs
+++ b/grep/src/search.rs
@@ -318,12 +318,29 @@ impl<'b, 's> Iterator for Iter<'b, 's> {
fn has_uppercase_literal(expr: &Expr) -> bool {
use syntax::Expr::*;
+ fn byte_is_upper(b: u8) -> bool { b'A' <= ... | 2 | 25 | 1 |
687e8469446634261ec24e40764a81140a218734 | Simen Bekkhus | 2016-11-25T14:24:27 | Add stylus type | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index 4483545..ece1cd1 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -153,6 +153,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("scala", &["*.scala"]),
("sh", &["*.bash", "*.csh", "*.ksh", "*.sh", "*.tcs... | 1 | 1 | 0 |
e3959d67a69b54e09f09ab3d3d1b4f60ae8b928c | Simen Bekkhus | 2016-11-25T08:53:19 | Re-add zsh types
Seems like #197 got lost in #202 | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index 4483545..e30f2bc 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -170,6 +170,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("xml", &["*.xml"]),
("yacc", &["*.y"]),
("yaml", &["*.yaml", "*.yml"])... | 1 | 1 | 0 |
42223047a858240cfeabcde4fd99b7395b34b297 | Michael Vitz | 2016-11-22T10:19:24 | Add type for Less
Less files use .less as extension. | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index af78a22..4483545 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -123,6 +123,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
]),
("json", &["*.json"]),
("jsonl", &["*.jsonl"]),
+ ("less", &["*.... | 1 | 1 | 0 |
42afb6faa5dbc9d11aa94a49691997093d21b237 | Michael Vitz | 2016-11-22T10:17:10 | Add type for Sass
Sass files use .scss as extension. | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index 38caf3b..af78a22 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -148,6 +148,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("rst", &["*.rst"]),
("ruby", &["*.rb"]),
("rust", &["*.rs"]),
+ ("s... | 1 | 1 | 0 |
05b26d59868687860c15a5d39e7570ee35a35503 | Andrew Gallant | 2016-11-22T01:33:57 | bump termcolor | diff --git a/Cargo.lock b/Cargo.lock
index b033753..ae31e31 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -16,7 +16,7 @@ dependencies = [
"memmap 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
"num_cpus 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"regex 0.1.80 (registry+https://... | 1 | 2 | 2 |
506f046b8b3882567bb589de574373c9c0f310c2 | Andrew Gallant | 2016-11-22T01:33:39 | termcolor-0.1.1 | diff --git a/termcolor/Cargo.toml b/termcolor/Cargo.toml
index 2814a6a..0f92c7f 100644
--- a/termcolor/Cargo.toml
+++ b/termcolor/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "termcolor"
-version = "0.1.0" #:version
+version = "0.1.1" #:version
authors = ["Andrew Gallant <jamslam@gmail.com>"]
description = """
A ... | 1 | 1 | 1 |
ae592b11e3b5d77a5cd1de02e01b4e370e5d72d6 | Andrew Gallant | 2016-11-22T01:33:15 | Only emit bold ANSI code if bold is true.
This was a simple logic error. Also, avoid emitting ANSI escape codes
if there are no color settings.
Fixes #242 | diff --git a/src/printer.rs b/src/printer.rs
index 4c04c0e..0a75f94 100644
--- a/src/printer.rs
+++ b/src/printer.rs
@@ -260,7 +260,7 @@ impl<W: WriteColor> Printer<W> {
}
fn write_matched_line(&mut self, re: &Regex, buf: &[u8]) {
- if !self.wtr.supports_color() {
+ if !self.wtr.supports_color... | 2 | 7 | 2 |
a5e7f176f18bf61ae2117091de1d323be598c79d | Andrew Gallant | 2016-11-21T14:20:43 | Use clap ~2.18.0.
This is to ensure that we don't silently update a minor version of clap,
which could include a breaking change.
(An update to 2.19 should be done soon.) | diff --git a/Cargo.toml b/Cargo.toml
index 9357b7d..848b89c 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -26,7 +26,7 @@ path = "tests/tests.rs"
[dependencies]
bytecount = "0.1.4"
-clap = "2.18"
+clap = "~2.18.0"
ctrlc = "2.0"
env_logger = "0.3"
grep = { version = "0.1.4", path = "grep" } | 1 | 1 | 1 |
df72d8d1e0016b2235504b17451348e68522e187 | Andrew Gallant | 2016-11-20T20:44:19 | Make wincolor crate compilable on non-Windows platforms. | diff --git a/wincolor/src/lib.rs b/wincolor/src/lib.rs
index a210b4b..d5a98f9 100644
--- a/wincolor/src/lib.rs
+++ b/wincolor/src/lib.rs
@@ -3,6 +3,8 @@ This crate provides a safe and simple Windows specific API to control
text attributes in the Windows console. Text attributes are limited to
foreground/background co... | 2 | 231 | 221 |
d06f84ced349b97a5181abf5d9e3029e18ee2b1c | Andrew Gallant | 2016-11-20T20:32:50 | Get rid of special mmap decision on Windows.
I spent some quality time on my Windows 10 laptop and it appears to
suffer from a similar trade-off as on Linux: mmaps are bad for large
directory traversals but good for single large files.
Darwin continues to reject memory maps in all cases (unless explicitly
requested),... | diff --git a/src/args.rs b/src/args.rs
index aa8f276..77421c4 100644
--- a/src/args.rs
+++ b/src/args.rs
@@ -504,9 +504,6 @@ impl<'a> ArgMatches<'a> {
false
} else if self.is_present("mmap") {
true
- } else if cfg!(windows) {
- // On Windows, memory maps appear faste... | 1 | 0 | 3 |
9598331fa81c653dd581f750494e0dc51cca1963 | Andrew Gallant | 2016-11-20T19:27:18 | Propagate no_messages option to worker.
Fixes #241 | diff --git a/src/args.rs b/src/args.rs
index a98a1b6..aa8f276 100644
--- a/src/args.rs
+++ b/src/args.rs
@@ -197,6 +197,7 @@ impl Args {
.invert_match(self.invert_match)
.max_count(self.max_count)
.mmap(self.mmap)
+ .no_messages(self.no_messages)
.quiet(sel... | 2 | 9 | 0 |
0302d58eb8b064da91e67de00aa25f542d1ff666 | Andrew Gallant | 2016-11-18T01:48:11 | Fix stdin bug with --file.
When `rg -f-` is used, the default search path should be `./` and not
`-`. | diff --git a/src/args.rs b/src/args.rs
index 97cf24f..a4955d5 100644
--- a/src/args.rs
+++ b/src/args.rs
@@ -370,10 +370,15 @@ impl<'a> ArgMatches<'a> {
/// Return the default path that ripgrep should search.
fn default_path(&self) -> PathBuf {
+ let file_is_stdin =
+ self.values_of_os("fi... | 1 | 7 | 2 |
e37f783fc00e9fa0e27450315c1e756918294e04 | Andrew Gallant | 2016-11-18T01:29:53 | Fix issue number mixup.
Thanks @bluss! | diff --git a/tests/tests.rs b/tests/tests.rs
index 2d6f2d3..bdafb29 100644
--- a/tests/tests.rs
+++ b/tests/tests.rs
@@ -896,22 +896,15 @@ clean!(regression_206, "test", ".", |wd: WorkDir, mut cmd: Command| {
});
// See: https://github.com/BurntSushi/ripgrep/issues/210
-clean!(regression_210, "test", ".", |wd: Work... | 1 | 9 | 9 |
a3f5e0c3d5f5c5088979a768765f988bf73dbf69 | Andrew Gallant | 2016-11-17T21:53:41 | Use env::home_dir() instead of env::var_os(HOME).
Thanks @steveklabnik! | diff --git a/ignore/src/gitignore.rs b/ignore/src/gitignore.rs
index 5523fa6..6a0bc96 100644
--- a/ignore/src/gitignore.rs
+++ b/ignore/src/gitignore.rs
@@ -453,9 +453,9 @@ fn gitconfig_contents() -> Option<Vec<u8>> {
/// Specifically, this respects XDG_CONFIG_HOME.
fn excludes_file_default() -> Option<PathBuf> {
... | 1 | 3 | 3 |
e9cd0a1cc39a2087600976189bf3b7c489d7ca1c | Eric Kidd | 2016-11-09T11:07:53 | Allow specifying patterns with `-f FILE` and `-f-`
This is a somewhat basic implementation of `-f-` (#7), with unit tests.
Changes include:
1. The internals of the `pattern` function have been refactored to avoid
code duplication, but there's a lot more we could do. Right now we
read the entire pattern list in... | diff --git a/src/args.rs b/src/args.rs
index 521dda8..cb858f8 100644
--- a/src/args.rs
+++ b/src/args.rs
@@ -1,6 +1,7 @@
use std::cmp;
use std::env;
-use std::io;
+use std::fs;
+use std::io::{self, BufRead};
use std::path::{Path, PathBuf};
use std::process;
@@ -34,6 +35,7 @@ use Result;
/// (TL;DR: The CLI parse... | 3 | 91 | 17 |
5ee175beaf6f5beb4d80b694ac535517c831d539 | Justin Puah | 2016-11-15T09:57:38 | Added elixir to types | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index ff243dd..38caf3b 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -102,6 +102,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("dart", &["*.dart"]),
("d", &["*.d"]),
("elisp", &["*.el"]),
+ ("el... | 1 | 1 | 0 |
4b18f828990c4e135207a5e641b679da1ac239df | Andrew Gallant | 2016-11-11T11:44:23 | Disable symlink tests on Windows.
For some reason, these work on AppVeyor but not in other build systems.
Let's just disable them.
See: https://github.com/rust-lang/rust/pull/37149 | diff --git a/tests/tests.rs b/tests/tests.rs
index 5c5546d..2a53c47 100644
--- a/tests/tests.rs
+++ b/tests/tests.rs
@@ -552,6 +552,7 @@ sherlock:be, to a very large extent, the result of luck. Sherlock Holmes
assert_eq!(lines, expected);
});
+#[cfg(not(windows))]
sherlock!(symlink_nofollow, "Sherlock", ".", |... | 1 | 2 | 0 |
5462af443494258822fa9e9cdfc5b33e1712a0b8 | Andrew Gallant | 2016-11-10T01:28:58 | Pin rustc-serialize to 0.3.19.
See: https://github.com/rust-lang-nursery/rustc-serialize/pull/159 | diff --git a/Cargo.lock b/Cargo.lock
index 149011d..ecca381 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -16,7 +16,7 @@ dependencies = [
"memmap 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
"num_cpus 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"regex 0.1.80 (registry+https://... | 2 | 5 | 5 |
64dc9b67092cec0faf6aeb03498d184b8851a4aa | Andrew Gallant | 2016-11-09T23:54:22 | update deps | diff --git a/Cargo.lock b/Cargo.lock
index 90fd5d7..378b026 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -7,7 +7,7 @@ dependencies = [
"docopt 0.6.86 (registry+https://github.com/rust-lang/crates.io-index)",
"env_logger 0.3.5 (registry+https://github.com/rust-lang/crates.io-index)",
"grep 0.1.4",
- "ignore 0.1.4",... | 2 | 7 | 7 |
9ffd4c421f3f386ef1d944a2b636c1fa0cee4ea2 | Andrew Gallant | 2016-11-09T23:52:52 | ignore-0.1.5 | diff --git a/ignore/Cargo.toml b/ignore/Cargo.toml
index dda954d..152a895 100644
--- a/ignore/Cargo.toml
+++ b/ignore/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "ignore"
-version = "0.1.4" #:version
+version = "0.1.5" #:version
authors = ["Andrew Gallant <jamslam@gmail.com>"]
description = """
A fast library fo... | 1 | 1 | 1 |
5b73dcc8abc3133c98603c64339c35e0ed90c577 | Andrew Gallant | 2016-11-09T22:19:40 | Rework parallelism in directory iterator.
Previously, ignore::WalkParallel would invoke the callback for all
*explicitly* given file paths in a single thread, which effectively
meant that `rg pattern foo bar baz ...` didn't actually search foo, bar
and baz in parallel.
The code was structured that way to avoid spinni... | diff --git a/ignore/src/walk.rs b/ignore/src/walk.rs
index f82b233..43b1049 100644
--- a/ignore/src/walk.rs
+++ b/ignore/src/walk.rs
@@ -747,40 +747,33 @@ impl WalkParallel {
let mut f = mkf();
let threads = self.threads();
let queue = Arc::new(MsQueue::new());
- let mut any_dirs = fal... | 2 | 36 | 28 |
2dce0dc0df3c9ade3d89dd1ed673213d76760509 | Andrew Gallant | 2016-11-09T21:45:21 | Fix a bug with handling --ignore-file.
Namely, passing a directory to --ignore-file caused ripgrep to allocate
memory without bound.
The issue was that I got a bit overzealous with partial error
reporting. Namely, when processing a gitignore file, we should try
to use every pattern even if some patterns are invalid g... | diff --git a/ignore/src/gitignore.rs b/ignore/src/gitignore.rs
index c44910f..5523fa6 100644
--- a/ignore/src/gitignore.rs
+++ b/ignore/src/gitignore.rs
@@ -311,7 +311,7 @@ impl GitignoreBuilder {
Ok(line) => line,
Err(err) => {
errs.push(Error::Io(err).tagged(path... | 3 | 9 | 2 |
f24873c70b7f352f412359b15942754301424091 | Andrew Gallant | 2016-11-07T00:02:14 | Don't ever search directories. | diff --git a/src/main.rs b/src/main.rs
index 8b7a267..b184a03 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -271,16 +271,15 @@ fn get_or_log_dir_entry(
eprintln!("{}", err);
}
}
- // A depth of 0 means the user gave the path explicitly, so we
- //... | 1 | 5 | 6 |
9fc9f368f5dc3d7d78fb8e68bea1c0a07a2aa32f | Andrew Gallant | 2016-11-06T23:23:50 | Always search paths given by user.
This permits doing `rg -a test /dev/sda1` for example, where as before
/dev/sda1 was skipped because it wasn't a regular file. | diff --git a/src/main.rs b/src/main.rs
index 41f13be..8b7a267 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -271,10 +271,19 @@ fn get_or_log_dir_entry(
eprintln!("{}", err);
}
}
- if !dent.file_type().map_or(true, |x| x.is_file()) {
- None
- ... | 1 | 12 | 3 |
4ca15a8a510a1359efc8ced7c26a374839561582 | Andrew Gallant | 2016-11-06T21:15:23 | simd-accel should not invoke avx-accel.
This was a silly transcription error. | diff --git a/Cargo.toml b/Cargo.toml
index db2b201..ca4a33d 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -46,7 +46,7 @@ winapi = "0.2"
[features]
avx-accel = ["bytecount/avx-accel"]
-simd-accel = ["bytecount/avx-accel", "regex/simd-accel"]
+simd-accel = ["bytecount/simd-accel", "regex/simd-accel"]
[profile.releas... | 1 | 1 | 1 |
dada75d2a715929c0fc5d8a320bac5c403d4449d | Andrew Gallant | 2016-11-06T20:48:40 | Update sub-crate dependency versions. | diff --git a/Cargo.lock b/Cargo.lock
index 7b50273..2f75a36 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -6,8 +6,8 @@ dependencies = [
"ctrlc 2.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"docopt 0.6.86 (registry+https://github.com/rust-lang/crates.io-index)",
"env_logger 0.3.5 (registry+https://... | 3 | 9 | 9 |
76b9f01ad24bc98ba54bdabd36781cc3e08c4081 | Andrew Gallant | 2016-11-06T20:35:21 | ignore-0.1.4 | diff --git a/ignore/Cargo.toml b/ignore/Cargo.toml
index 635299f..5d4db43 100644
--- a/ignore/Cargo.toml
+++ b/ignore/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "ignore"
-version = "0.1.3" #:version
+version = "0.1.4" #:version
authors = ["Andrew Gallant <jamslam@gmail.com>"]
description = """
A fast library fo... | 1 | 1 | 1 |
8baa0e56b7f21643281a781293cfd82a66de2251 | Andrew Gallant | 2016-11-06T20:35:17 | grep-0.1.4 | diff --git a/grep/Cargo.toml b/grep/Cargo.toml
index 8637f16..7d266a0 100644
--- a/grep/Cargo.toml
+++ b/grep/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "grep"
-version = "0.1.3" #:version
+version = "0.1.4" #:version
authors = ["Andrew Gallant <jamslam@gmail.com>"]
description = """
Fast line oriented regex se... | 1 | 1 | 1 |
301ee6d3f52f8c004d3cc7ab45b49d116f16a2fb | Andrew Gallant | 2016-11-06T20:35:05 | globset-0.1.2 | diff --git a/globset/Cargo.toml b/globset/Cargo.toml
index 82d01a3..f895495 100644
--- a/globset/Cargo.toml
+++ b/globset/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "globset"
-version = "0.1.1" #:version
+version = "0.1.2" #:version
authors = ["Andrew Gallant <jamslam@gmail.com>"]
description = """
Cross platfo... | 1 | 1 | 1 |
351eddc17e3f7164978c2f001ff9b8e3bc328e33 | Andrew Gallant | 2016-11-06T17:23:42 | Add new 'h' file type.
This is intended to correspond to C/C++ header files.
Fixes #186 | diff --git a/ignore/src/types.rs b/ignore/src/types.rs
index 15e5876..ff243dd 100644
--- a/ignore/src/types.rs
+++ b/ignore/src/types.rs
@@ -111,6 +111,7 @@ const DEFAULT_TYPES: &'static [(&'static str, &'static [&'static str])] = &[
("fsharp", &["*.fs", "*.fsx", "*.fsi"]),
("go", &["*.go"]),
("groovy", ... | 1 | 1 | 0 |
0222e024fef6c52fc1cd01b6c7ec01ab38031bce | Andrew Gallant | 2016-11-06T17:07:47 | Fixes a bug with --smart-case.
This was a subtle bug, but the big picture was that the smart case
information wasn't being carried through to the literal extraction in
some cases. When this happened, it was possible to get back an incomplete
set of literals, which would therefore miss some valid matches.
The fix to t... | diff --git a/grep/src/literals.rs b/grep/src/literals.rs
index 4cd34a8..d931f13 100644
--- a/grep/src/literals.rs
+++ b/grep/src/literals.rs
@@ -9,7 +9,7 @@ principled.
*/
use std::cmp;
-use regex::bytes::Regex;
+use regex::bytes::RegexBuilder;
use syntax::{
Expr, Literals, Lit,
ByteClass, ByteRange, Cha... | 3 | 51 | 20 |
02de97b8ce2762a7530cc18bba737f6ccea022a2 | Andre Bogus | 2016-09-23T02:59:25 | Use the bytecount crate for fast line counting.
Fixes #128 | diff --git a/Cargo.lock b/Cargo.lock
index d6f512f..d497e7b 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -2,6 +2,7 @@
name = "ripgrep"
version = "0.2.6"
dependencies = [
+ "bytecount 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
"ctrlc 2.0.1 (registry+https://github.com/rust-lang/crates.io-index)"... | 5 | 26 | 82 |
f63c168563743ddc402335893a9cacfcb780ccc9 | Jacob Wahlgren | 2016-11-06T00:17:41 | Rename IgnoreOptions::has_ignores
The name has_ignores is not descriptive in my opinion. I think
has_any_ignore_options more clearly states this method's purpose. I also
considered simply IgnoreOptions::any though I went with the more verbose
option. | diff --git a/ignore/src/dir.rs b/ignore/src/dir.rs
index ebc2c69..370fd92 100644
--- a/ignore/src/dir.rs
+++ b/ignore/src/dir.rs
@@ -75,7 +75,7 @@ struct IgnoreOptions {
impl IgnoreOptions {
/// Returns true if at least one type of ignore rules should be matched.
- fn should_ignores(&self) -> bool {
+ fn ... | 1 | 2 | 2 |
a05671c8d72659c1189eefea15f798c20407282a | Jacob Wahlgren | 2016-11-06T00:01:14 | Use new Match::or to simplify return | diff --git a/ignore/src/dir.rs b/ignore/src/dir.rs
index 6ac0062..ebc2c69 100644
--- a/ignore/src/dir.rs
+++ b/ignore/src/dir.rs
@@ -360,19 +360,8 @@ impl Ignore {
}
let m_global = self.0.git_global_matcher.matched(&path, is_dir)
.map(IgnoreMatch::gitignore);
- if !m... | 2 | 11 | 13 |
1aeae3e22da4e9ffa78ece485369e7a24744b2d4 | Andrew Gallant | 2016-11-05T01:12:08 | update ripgrep | diff --git a/Cargo.lock b/Cargo.lock
index 7bf1de7..6e17145 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -1,6 +1,6 @@
[root]
name = "ripgrep"
-version = "0.2.5"
+version = "0.2.6"
dependencies = [
"ctrlc 2.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"deque 0.3.1 (registry+https://github.com/rust... | 1 | 1 | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.