From owner-freebsd-questions@FreeBSD.ORG Sat Jan 5 06:11:21 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 30B9516A47E for ; Sat, 5 Jan 2008 06:11:21 +0000 (UTC) (envelope-from wtf.jlaine@gmail.com) Received: from rv-out-0910.google.com (rv-out-0910.google.com [209.85.198.188]) by mx1.freebsd.org (Postfix) with ESMTP id 7BEA613C458 for ; Sat, 5 Jan 2008 06:11:20 +0000 (UTC) (envelope-from wtf.jlaine@gmail.com) Received: by rv-out-0910.google.com with SMTP id l15so6870584rvb.43 for ; Fri, 04 Jan 2008 22:11:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; bh=U7RusgSOTZkxjWeTK5uwYgxysQuWJfRzoSneOKysSYE=; b=bP/ofNRR7f3yTEOSSFSjYPEbjVkvkE/k9Py4kj2X8bTQ5WAhXLgMjP6F3m2Uq1GLCDNcCTh3TUCs48IuBS+lAGO0wCwl1Q/LBIIREzH2u6/Gx/GowvCArGYWDfSFqH4sC+RCzisS8hjWmJHP7CteI35iCU31+AUgB7y0fXkXXDg= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=P//5UMo3meBr5yTWdaHe+8EaM/OZeRVLlJRKx0vDGshIPw7l5lH5AOTQ+1hvRzX/gmHzwB0QzzjMTTpAqC056Or7VfPnOhMBc9omIcvZsgtezj2pdXwdcqzwb7kWGKitiKZyyeohoYLHTxGSU4WCiDuwxEXjTv0jAoMk/7+1PYA= Received: by 10.141.113.6 with SMTP id q6mr9339273rvm.249.1199513479902; Fri, 04 Jan 2008 22:11:19 -0800 (PST) Received: by 10.140.143.2 with HTTP; Fri, 4 Jan 2008 22:11:19 -0800 (PST) Message-ID: <2b98f2f70801042211o40e978efqe7c5c6c9f16e241a@mail.gmail.com> Date: Sat, 5 Jan 2008 11:11:19 +0500 From: "Jeff Laine" To: "Aryeh M. Friedman" In-Reply-To: <477F1D54.3040807@gmail.com> MIME-Version: 1.0 References: <2b98f2f70801042134x1af4f721s877677afde7151f5@mail.gmail.com> <477F1D54.3040807@gmail.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: freebsd-questions@freebsd.org Subject: Re: batch rename 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: Sat, 05 Jan 2008 06:11:21 -0000 On 05/01/2008, Aryeh M. Friedman wrote: > > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Jeff Laine wrote: > > Hi to all. > > > > My goal is to rename several files in such a way as to decapitalize > > starting letters in their names. The solution seems to be simple > > but I'm stuck. What should I use? awk/sed or write some > > shell-script? > > This assumes tcsh: > > foreach i (`ls [A-Z][a-z]*`) > mv $i `echo $i|tr 'A-Z' 'a-z'` > end > Thanks! It was simple after all. Doh, I've never heard about "tr" before. -- --Jeff--