3 ms·
In the first case, it's searching in parallel, so I bet the order of results is different each time. In the second case, rg each > foo2 found results in foo1 a
by ggreer 10y ago
In the first case, it's searching in parallel, so I bet the order of results is different each time.
In the second case, rg each > foo2 found results in foo1 and put them in foo2. Then rg each > foo3 found results in foo1 and foo2, and put them in foo3. Etc. That's why the file size increases so quickly.
- coldtea 10y ago>In the first case, it's searching in parallel, so I bet the order of results is different. Aha. Thought that needed the -j flag (it says: default threads: 0 in the cli help). Could it do anything to put them out in order of "depth" (and directory/file sorting order)? >In the second case, rg each > foo2 found results in foo1 and put them in foo2. Then rg each > foo3 found results in foo1 and foo2, and put them in foo3. Etc. That's why the file size increases so quickly. LOL, facepalm -- yes.
- ggreer 10y agoForcing it to use one worker (-j1, I think) should give it deterministic output.