Date: Thu, 1 Aug 2002 00:02:51 +0200 From: Ian Barwick <barwick@gmx.net> To: Maciej Szewczyk <rodion@pirx.9lo.lublin.pl>, questions@freebsd.org Subject: Re: files to files with .txt Message-ID: <200208010002.51591.barwick@gmx.net> In-Reply-To: <20020731230256.A19666@pirx.9lo.lublin.pl> References: <20020731230256.A19666@pirx.9lo.lublin.pl>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wednesday 31 July 2002 23:02, Maciej Szewczyk wrote: > Hi, > I have about 1000 files. > ls -1 > 1 > 2 > 3 (...) > ... > ... > 998 > 999 > 1000 > And now I must have 1000 files with .txt -> > ls -1 > 1.txt > 2.txt > 3.txt > ... > ... > 998.txt > 999.txt > 1000.txt > Something along the lines of: find -E . -regex './[0-9]+' -exec mv {} {}.txt \; You'll want to be sure that 'find' finds the right files to rename. HTH Ian Barwick barwick@gmx.net To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200208010002.51591.barwick>