Re: GREP Help



On Jan 31, 11:56 am, "M" <n...@xxxxxxxxxxxxxxxxxx> wrote:
Is there a wa with grep to extract all lines that do not begin with "#"? I
have tried the following.

grep -v '#' /etc/my.conf

grep -v '^#' /etc/my.conf

The ^ indicates the start of a line, so '^#' indicates lines that have
a # at the start, and -v '^#' indicates lines that do not have a # at
the start.

HTH
-
Lew



.