Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Programming and Hacking > Development

 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
Old 13th February 2005, 13:41   #1  |  Link
video_magic
Registered User
 
Join Date: Jan 2005
Posts: 368
DOS Batch file. How to rename a file to have the current directory name?

Hello. I have made a very simple batchfile, named dirmp3.bat, to create a playlist of all mp3s in the current Folder. The contents of dirmp3.bat so far are:

dir /B /O *.mp3 > ppp.m3u

I then want to rename ppp.m3u to be "name of current folder".m3u
Or preferably output to "name of current folder".m3u in the first place and miss out the renaming step.

I've looked on the internet and have also tried fiddling around with some Dos commands but can't figure out how to do it. I would like a way that is safe for all Windows versions of Dos if possible - i.e. folder names containing spaces, and if there is a way that would also be safe in True MSDos so much the better

Thanks if someone can give an example or point to a link
__________________
Thankyou!, I am grateful for any help
video_magic is offline   Reply With Quote
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 05:52.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2017, vBulletin Solutions Inc.