Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

In Dutch.... sowwy....

9 views
Skip to first unread message

Cor

unread,
May 23, 2012, 4:58:23 PM5/23/12
to
Zijn er ook mensen die goed zijn met DOS-commando's schrijven? Ik heb me het
leplazarus gezocht op het Internet, maar kan niet exact vinden wat ik zoek.

Mijn punt is deze:

Stel, ik heb onder andere een directory genaamd AM. Deze loopt van Amalia
Rodriguez tot en met Amy Winehouse.

Zie? Alles begint me Am.

Is het mogelijk een DOS commando te schrijven die alle bestanden <MET
DEZELFDE NAAM> in 1 directory gooit, met DIE NAAM?

En dan praat ik over A t/m Z als hoofd-directory, en alle sub-directories
daarin.... zoals die AM.

Dus: A\AA t/m A\AZ................................. en dan helemaal door tot
en met Z\ZZ.

Alleen al voor mijn "losse mp3's praat ik al over ongeveer 65000 mp3's in
ongeveer 540 directories..... en werkelijk helse klus om dat met de hand te
doen.

Ben benieuwd!

Groetjes!!

Cor







Message has been deleted

foxidrive

unread,
May 23, 2012, 9:09:21 PM5/23/12
to
On 24/05/2012 06:58, Cor wrote:

Google translation:

> Are there people who are good with DOS commands write? I have the
> leplazarus searched on the Internet, but can not find exactly what I want.
>
> My point is this:
>
> Suppose I have include a directory named AM. It runs from Amalia
> Rodriguez to Amy Winehouse.
>
> See? Everything starts I Am
>
> Is it possible to write a DOS command that all files <WITH
> SAME NAME> throws in 1 directory with that name?
>
> And I talk about A t / m Z as main directory and all subdirectories
> therein .... such as those AM.
>
> So: A \ AA t / m A \ AZ ................................. and then all the way to
> and Z \ ZZ.
>
> Just for my "loose talk mp3's I already have about 65,000 mp3's in
> approximately 540 directories ..... and actually infernal job to that with the hand
> do.
>
> I'm curious!
>
> Greetings!
>
> Cor


The file naming sequence helps to determine how easy it is.

Do you use "artist - title.mp3" or some other scheme?

when you have artists like "AC/DC" do you have "AC - DC - Title" or "AC-DC - Title"

The way to do it using this naming scheme is to detect the " - " and then make the directory with the name and move "%name% - *.mp3" "%name%".


Google Translate:
================

De bestandsnamen volgorde helpt om te bepalen hoe gemakkelijk het is.

Maakt u gebruik van "kunstenaar - titel.mp3" of een andere regeling?

als je artiesten als "AC / DC" heb je "AC - DC - Titel" of "AC-DC - Titel"

De manier om het te doen met behulp van deze naam schema is op te sporen op de "-" en dan de map te maken met de naam en het te verplaatsen "% name% -. * Mp3" "% name%".



--
Mic

billious

unread,
May 24, 2012, 1:39:55 AM5/24/12
to
If I understand correctly, you want to move files named xy*.mp3 to ...\x\xy\

@echo off
setlocal enabledelayedexpansion
for /f "delims=" %%i in (
' dir /b /s c:\sourcedir\*.mp3 '
) do (call :first2 "%%~ni"
md c:\destdir\!dest! 2>nul
ECHO move "%%i" "c:\destdir\!dest!\"
)
goto :eof

:first2
set dest=%1
:again
if /i "%dest:~1,4%"=="the " set dest="%dest:~5%&goto again
set dest=%dest:~1,1%\%dest:~1,2%
goto :eof


Note that the IF/I in the FIRST2 routine removes "the " from the name, so

The Animals -> a\an
The Beatles -> b\be
The Moody Blues -> m\mo

NB The ECHO in the ECHO move line will SHOW the command to be executed.
Remove the ECHO keyword after verification to actually perform the move.

HTH

(Translation if required is your problem...)
Message has been deleted
Message has been deleted
0 new messages