it works with grep -i reboot *

Sorry for the inconvenience.

On 2020-06-07 06:40, Sebastien Marie wrote:
On Sat, Jun 06, 2020 at 07:57:35PM +0200, BESSOT Jean-Michel wrote:
yes, "reboot"

On 2020-06-06 17:51, Otto Moerbeek wrote:
On Sat, Jun 06, 2020 at 05:44:24PM +0200, BESSOT Jean-Michel wrote:

I did run grep reboot and grep -i reboot in /usr/src/usr.sbin/cron/
So did you give a file argument?

Just a try.

If you just did:

$ cd /usr/src/usr.sbin/cron
$ grep -i reboot

It is expected that the command do nothing obvious.

For quoting the grep(1) manual:

        If no file arguments are specified, the standard input is used.


If you want grepping for files inside the current directory, you should also
pass -R option:

        Recursively search subdirectories listed.  If no file is given,
        grep searches the current working directory.

Please note that the behaviour of the last part 'If no file is given, ...' is
present in 6.7 and not in 6.6 (changed on 2019-12-02 with c1cbe94b).

Thanks.

Reply via email to