From owner-freebsd-questions@FreeBSD.ORG Sat Nov 29 17:33:23 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D96471065670 for ; Sat, 29 Nov 2008 17:33:23 +0000 (UTC) (envelope-from sahil@tandon.net) Received: from aegis.hamla.org (aegis.hamla.org [206.251.255.39]) by mx1.freebsd.org (Postfix) with ESMTP id BA0828FC13 for ; Sat, 29 Nov 2008 17:33:23 +0000 (UTC) (envelope-from sahil@tandon.net) Received: from localhost (localhost [127.0.0.1]) by aegis.hamla.org (Postfix) with ESMTP id 770FD5C78 for ; Sat, 29 Nov 2008 12:34:48 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tandon.net; h= x-virus-scanned:in-reply-to:content-disposition:content-type :mime-version:references:reply-to:message-id:subject:from:date: received; s=aegis; t=1227980088; bh=NyxDa/xZJGY/717CpT88AvOZzpwG QyM+dEHyDKlOSs4=; b=mQB41KxlFqOrTz0wnzWKd73FDeqCZv5GkalpEos0rCG4 9ZymV0ktNR3nRO46tSOsLFvSRSR4FNwkvsaqNH4QQ2wY2y6dMT0wbt1ySFCC3LC4 y+e2WosZ9X54DRi9T1nOVVF9OvT+p7ae107um2WsfySMY2Y8rAct4oV+U3Gwl6w= Received: from aegis.hamla.org ([127.0.0.1]) by localhost (aegis.hamla.org [127.0.0.1]) (amavisd-new, port 10027) with LMTP id YGvOig0XxwYl for ; Sat, 29 Nov 2008 12:34:48 -0500 (EST) Date: Sat, 29 Nov 2008 12:33:22 -0500 From: Sahil Tandon To: freebsd-questions@freebsd.org Message-ID: <20081129173322.GB43599@shepherd> References: <20081129060801.GA41353@shepherd> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Virus-Scanned: ClamAV version 0.94, clamav-milter version 0.94 on aegis.hamla.org X-Virus-Status: Clean Subject: Re: shell scripting problems X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: "freebsd-questions@freebsd.org" List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 29 Nov 2008 17:33:23 -0000 Tim Judd wrote: > I'm sure it's faulty > > Which is why I'm asking for help > > My regexes (in it's various forms) produce the output similar to: > xorg-fonts-75dpi > xorg-fonts > xorg-fonts-100dpi > ... > ... > ... > > and I'm wanting my regex to return the 2nd value, in this example, in > this list. In your initial message, you wished to extract the first value; now it is the second? > The problem is the shell is taking the end anchor $ as the start of a > variable, and no matter how I escape it, it seems to never work. > > I'm sorry for not explaining properly. Maybe the above would help. It does not. Explain exactly what you are trying to do and you will receive more exact troubleshooting advice. And please stop top-posting. -- Sahil Tandon