help-bash
[Top][All Lists]
Advanced

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

[Help-bash] Any way to make ** search the current directory as well for


From: Peng Yu
Subject: [Help-bash] Any way to make ** search the current directory as well for files with a certain extension?
Date: Thu, 20 Dec 2018 10:00:23 -0600

Hi,

I could use the following to do so.

printf '%s\n' ** | grep '\.sh$'

But is there a way to get rid off the grep. The following will not
search for the current directory.

printf '%s\n' **/*.sh

Of course, one could write like this but it is a little cumbersome.

printf '%s\n' **/*.sh *.sh

Thanks.

-- 
Regards,
Peng



reply via email to

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