bug-parallel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ripgrep not working under parallel


From: Ole Tange
Subject: Re: ripgrep not working under parallel
Date: Tue, 16 Jul 2024 04:05:25 +0200

On Fri, Jul 5, 2024 at 3:05 AM Hong Yang <hyangfji@gmail.com> wrote:

> I use ripgrep to search things, but it does not work under parallel.
:
I can reproduce this.

> What do you believe could be responsible for this?

It seems rg wants a terminal:

    parallel -o 'echo {};rg {};echo {}' ::: foo bar baz
    parallel 'echo {};rg {} < /dev/tty;echo {}' ::: foo bar baz
    parallel -o 'echo {};rg --color always {};echo {}' ::: foo bar baz

To me it seems like a bug in rg to refuse any output instead of
falling back to text-only mode.

GNU Parallel sets up a new process group for each task. This way GNU
Parallel can kill the whole group if --timeout or similar is used. In
this process the terminal is also changed.


/Ole



reply via email to

[Prev in Thread] Current Thread [Next in Thread]