Article View: nl.comp.overig
Article #198Re: multi-file rename utility
From: Hennes Passmann
Date: Fri, 28 Apr 2000 00:00
Date: Fri, 28 Apr 2000 00:00
25 lines
1425 bytes
1425 bytes
In nl.comp.overig Marc Alcide <marc.alcide@mechelen.be> wrote: > Hello, > Ik zoek een tool om (in mijn geval) 5381 files te hernoemen van > name.mp3 naar name-nl.mp3 Gebruik een shell script: for a in *mp3; do mv $a `echo $a | cut -d. -f1`-nl.mp3 ;done Uitleg: for a in *mp3 selecteerd alle bestanden in de dir die eindigen op mp3 mv move 'oude_naam' 'nieuwe_naam' echo $a laat de naam van de huidige file zien cut 'knipt' daar een stuk vanaf (in dit geval alles na de punt Dit script werkt zowel onder BSD, linux en vast ook op een tiental anndere unix varianten. Als je ms-windows gebruikt, mount dan partitie met de MP3s op een unix bak (bv samba) of installeerd cygnus utils en soortgenoten. > Dank bij voorbaat > Marc Alcide > marc.alcide@mechelen.be -- Hennes@stack.nl
Technical Details
Message-ID:
<8echu3$7s$1@news.tue.nl>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<390997c9.17474959@news.club.innet.be>Show Full Headers
Complete Article Headers
X-Google-Language: DUTCH,ASCII-7-bit
X-Google-Thread: 114f70,3e7f6dc581b63902
X-Google-Attributes: gid114f70,public
X-Google-Thread: 111c4c,3e7f6dc581b63902
X-Google-Attributes: gid111c4c,public
From: Hennes Passmann <hennes@stack.nl>
Subject: Re: multi-file rename utility
Date: 2000/04/28
Message-ID: <8echu3$7s$1@news.tue.nl>
X-Deja-AN: 616860867
References: <390997c9.17474959@news.club.innet.be>
Organization: Eindhoven University of Technology, The Netherlands
User-Agent: tin/1.4.2-20000205 ("Possession") (UNIX) (FreeBSD/3.4-RELEASE (i386))
Newsgroups: nl.comp.overig,be.comp