bug-findutils
[Top][All Lists]
Advanced

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

Support for inline input


From: Kristian Benoit
Subject: Support for inline input
Date: Thu, 12 Oct 2017 16:16:37 -0400

It took me time trying to remove './' at the beginning of each line of
output. The problem is that I tried with '-exec'. I got it working
this way:

find . -maxdepth 1 -type d | sed -e 's/^\.\///'

I don't know why I didn't thought of using a pipe, but it could be
nice to have the output piped to the exec function, lets say with
pexec.

find . -maxdepth 1 -type d -pexec sed -e 's/^\.\///' \;

This way the param to pexec could handle only one line, not the whole
output at once. I'm saying this because it could be nice to enhance
cooperation between GNU tools.

Kristian



reply via email to

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