From owner-freebsd-questions@FreeBSD.ORG Mon Feb 14 23:11:20 2011 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 B30F2106566B for ; Mon, 14 Feb 2011 23:11:20 +0000 (UTC) (envelope-from amvandemore@gmail.com) Received: from mail-fx0-f54.google.com (mail-fx0-f54.google.com [209.85.161.54]) by mx1.freebsd.org (Postfix) with ESMTP id 43C768FC08 for ; Mon, 14 Feb 2011 23:11:19 +0000 (UTC) Received: by fxm16 with SMTP id 16so5934186fxm.13 for ; Mon, 14 Feb 2011 15:11:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=+H5oib/yw3mLV2oMq0fPZEJFv6QL5J3J50+zLZhC9eA=; b=mEDmwTvqMFzKgrRslp+rsarkOz1pZ/ZumZfokjngZdpyCufWvRAleSJx8l1imAjaJs UpCVyCERQx+/gbLuJPMemnpPG+wuvmQ2/DMjp9+27fKk04SB+wF1w6IMVO03nbFzep07 kT+DvgoXE9sdQr0kMHGNdkR8CcRsg4CNdv8rs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=tl6SfkO4zBnFTuszYMhEDhOdcfeqXAh/+hcqgR6GHDIwzhNomCI6gy0enqdfV84CvD 5NTPfnd8pjK/oSv3Wy9iSZ4otXxfRHI28mirls6BCx4+eMUVYpz1Cp2ZbYW0FI/SjuXL pLXbqKPvRURCnbN4R869g1yKMNJLq0wQtdlYo= MIME-Version: 1.0 Received: by 10.223.103.198 with SMTP id l6mr5291726fao.99.1297725079099; Mon, 14 Feb 2011 15:11:19 -0800 (PST) Received: by 10.223.94.67 with HTTP; Mon, 14 Feb 2011 15:11:19 -0800 (PST) In-Reply-To: <3.0.1.32.20110214163437.019167e0@sage-american.com> References: <3.0.1.32.20110214163437.019167e0@sage-american.com> Date: Mon, 14 Feb 2011 17:11:19 -0600 Message-ID: From: Adam Vande More To: "Jack L. Stone" Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: freebsd-questions@freebsd.org Subject: Re: script help X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 14 Feb 2011 23:11:20 -0000 On Mon, Feb 14, 2011 at 4:34 PM, Jack L. Stone wrote: > Hello folks: > > No doubt this will be easy for those with scritping abilities. > > I have a gazillion files by the same name and each contains the same line > requiring the same change. But the problem is that they are in many > different directories on a server with numerous domains. While I could > handle the change using a single directory within my abilities, I'm unsure > how to do a search and replace throughout the many domains and their > directories. Don't want to mess up. Here's what I'm trying to do: > > # find all of the same filenames (copyright.htm) and then replace the year > 2010 with 2011 in each file. Once I have a working script, I should be able > to add it as a cron job to run on the first day of each new year. > > Any help appreciated. > /usr/ports/misc/rpl -- Adam Vande More