delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2007/04/03/17:39:09

X-Spam-Check-By: sourceware.org
Mime-Version: 1.0 (Apple Message framework v752.2)
In-Reply-To: <mn.1b487d74cbed7dfa.51129@pbs.org>
References: <mn DOT 1b2c7d742b4ca532 DOT 51129 AT pbs DOT org> <019001c77617$8e0eabc0$2e08a8c0 AT CAM DOT ARTIMI DOT COM> <mn DOT 1b487d74cbed7dfa DOT 51129 AT pbs DOT org>
Message-Id: <796F3459-CF33-4CFD-A8A9-6C137F07CD0D@rehley.net>
Cc: cygwin AT cygwin DOT com
From: Peter Rehley <peter AT rehley DOT net>
Subject: Re: grep and exact matches help..
Date: Tue, 3 Apr 2007 14:38:49 -0700
X-Mailer: Apple Mail (2.752.2)
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On Apr 3, 2007, at 11:00 AM, Kevin Markle wrote:

> In this search I want to get winops only not winops and winops-hq
>
> kmarkle AT backup /cygdrive/e/wsus/group_1a_DEV
> $ ls -al | grep winops
> -rwx------+ 1 Administrators ???????? 1079474 Apr  2 19:32 winops- 
> hq_WINDOWSUpdate.log
> -rwx------+ 1 Administrators ????????   18993 Apr  3 13:02 winops- 
> hq_asr.log
> -rwx------+ 1 Administrators ???????? 1242842 Apr  3 06:01  
> winops_WINDOWSUpdate.log
> -rwx------+ 1 Administrators ????????   18580 Apr  3 13:02  
> winops_asr.log
>

Here is one possible solution

ls -1a | grep winops | grep -v winops-hp

or maybe this

ls -1a | sed -e '/winops-hq/d'


Peter

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019