DOS Command Line

merlin1949

New Member
Messages
30
Hi there-

Just reorganising my Library and for reasons I won't bore you with, need to do some mass amendments to Filenames to get rid of extraneous Info as I'm tight on Space.

So, for instance, I have a Folder (DIRectory) with one hundred PDF, Mobi, RAR, ZIP, CBR and CBZ files in it all with filenames in the following format :-

Henry Rider Haggard (Victorian Novelist, Africa Hand) [Title of Short Story/Novel/Graphic Novel].???

As :-

a) I do happen to know who H Rider Haggard is (having read my first book of his 55 years ago when I was Ten)
b) All the Files are going to go into a Directory (Folder) Entitled "Henry Rider Haggard" (in case I suddenly get struck down with Oldtimer's disease)

then I want to get rid of the words "Henry Rider Haggard (Victorian Novelist, Africa Hand)" which is common to every Filename.

My latest attempt at a Command Line blanket change from within the Folder (Directory) was the DOS command -

REN "Henry Rider Haggard (Victorian Novelist, Africa Hand)"*.??? *.???

I have also tried :-

Using the different extensions (.CBR .ZIP .RAR etc ) to change them 20 or 30 at a time
Using the same Format but *.* instead of *.???
Using no Inverted Commas on the part of the Description that I want to get rid of

Yes, I DO realise that in the time I have spent fiddling about with Command Line and composing this Post I COULD have done the whole thing Manually, BUT I have Sixty Five separate Authors to create Directories (Folders) for with about Five to 100 or so Short Stories/Novels etc. to change in exactly the same way (Many Titles will have entries in RAR, Mobi, PDF, CBR and CBZ formats so someone like Herbert George Wells has 135 individual Titles with over 850 separate Files.

"Have you no Sons and Daughters" I hear you say. "They would only be too pleased to take this onerous task off your aged and care burdened shoulders in the Twilight of your ears, repaying in some small measure the Years of Toil that you have endured on their behalf."

Al I can say to such a Naieve and disingenuous suggestion is "HA", "HA" and THRICE more "HA".

a) My Daughter, who is now 35, is WAY past the age of falling for a pound's worth of Choccies and a good book to perform these tasks for me

b) pretending to be THRILLED at the prospect of such a mind bendingly boring job in order to make her plead to help me only ever worked for Tom Sawyer

c) the Moral Blackmail, once extremely effective, became unusable due to over use many years ago. The days are LONG gone when I could happily rely on getting these little chores done with phrases like :-

"Don't you LOVE your poor Daddy, then, Bethan"

and

"You wouldn't like to see Daddy CRY, would you, darling"

and the ultimate

"I just wanted you to know that I've left everything to you in my Will. It's in that draw in the kitchen - just in case something happens to me. Sudden like. and I don't get a chance to say Goodbye"

So I've got to do it myself - with your help, of course.

After all, you wouldn't like to see an Old Man cry, would you...............

Merlin
 

My Computer

System One

  • OS
    Win 8.1
    Computer type
    PC/Desktop
There is no such thing as Dos. Dos went the way of the Dodo bird, after 98 died. You have a Command window, that you can do certain things in. But what you are wanting to do, I am lost. It sounds like you are telling a story, not asking a question.

If you want to change a file name, you do it from Explorer in the Desktop. If you want to edit a file, you do it from what ever program was used to create the file.
 

My Computer

System One

  • OS
    Linux Mint 17.2
    Computer type
    Laptop
    System Manufacturer/Model
    Toshiba Satellite C850D-st3nx1
    CPU
    AMD E1-1200 APU with Radeon (tm) HD Graphics 1.40 GHZ
    Memory
    12GB
    Graphics Card(s)
    AMD Radeon™ HD 7310 Graphics
    Sound Card
    Realtek HD
    Monitor(s) Displays
    LCD
    Screen Resolution
    1366 x 768
    Hard Drives
    Crucial M500 240GB SSD
    Mouse
    Logitech M525
    Internet Speed
    45/6 - ATT U-Verse
    Browser
    Google Chrome
    Antivirus
    None needed. It is Linux.
    Other Info
    Arris NVG589 Gateway; Router - Cisco RV320; Switch - Netgear GS108 8-Port Switch & Trendnet TEG-S50g 5-Port Switch; Access Points - Engenius ECB350, Trendnet TEW-638APB; NAS - Lenovo ix2-4; Printer - Brother HL-2280DW; Air Print Server - Lantronix XPrintServer

    A/V UPS - Tripp-Lite Smart 1500LCD 1500 Va/900 W.
Welcome to the forum.

Please post your question without the extraneous details.
 

My Computer

System One

  • OS
    Windows 7
    Computer type
    PC/Desktop
Is this spam with a story?
 

My Computer

System One

  • OS
    Windows 8.1 Pro 64-bit
    Computer type
    Laptop
    System Manufacturer/Model
    Acer V3 771G-6443
    CPU
    i5-3230m
    Motherboard
    Acer VA70_HC (U3E1)
    Memory
    8GB DDR3 PC3-12800 (800 MHz)
    Graphics Card(s)
    HD4000 + GeForce GT 730M
    Sound Card
    Realtek High Definition Audio
    Monitor(s) Displays
    17" Generic PnP Display on Intel HD Graphics 4000
    Screen Resolution
    1600x900 pixels
    Hard Drives
    Samsung SSD 850 EVO 250 GB
    ADATA SSD SP900 128GB
    PSU
    90 watt brick
    Mouse
    Bluetooth
    Antivirus
    Comodo
    Other Info
    Asus RT-AC56R dual-band WRT router (Merlin firmware). Intel 7260.HMWWB.R dual-band ac wireless adapter.
Hmm... I got a bit lost reading your post, but from what I gather you want to batch rename a bunch of files.
While you might be able to do that using DOS command and maybe a .bat file, you're probably better off using powershell.

Here are a few links that might interest you :
Use PowerShell to Rename Files in Bulk - Hey, Scripting Guy! Blog - Site Home - TechNet Blogs
Batch File Rename with Windows PowerShell
Rename-Item
Renaming Files - Windows PowerShell Blog - Site Home - MSDN Blogs

If you only want to organize your collection of ebooks, you should take a look at : calibre - E-book management
This is a free open-source software. It will automatically import all your ebooks (most format are supported, although I'm not sure about your .cbr/.cbz comics files), and then copy them in its libraries. Metadata like title/author/date of release/genre/etc... will be retrieved from the files, but you can edit/add them later on. This software should ease the organization of your collection much more than what you're trying to do.
It also includes an ebook reader, and can convert to most formats too. I assume the RAR/ZIP files contain ebooks in HTML format, Calibre will be able to convert them to epub, which is an already compressed (using zip compression) ebook format, which you can then directly open with the reader.
 

My Computer

System One

  • OS
    Windows 8.1 (x64)
    Computer type
    PC/Desktop
What do you mean there is no such thing as DOS ?

I was under the impression that DOS commands are still used in command prompt windows.


Merlin
 

My Computer

System One

  • OS
    Win 8.1
    Computer type
    PC/Desktop
Base on what you want to get done. Instead of using tedious DOS commands, you can download a free ware from the link below:
Bulk Rename Utility

Hope this helps !!!
 

My Computer

System One

  • OS
    8.1x64PWMC Ubuntu14.04x64 MintMate17x64
    Computer type
    PC/Desktop
    System Manufacturer/Model
    Home Brewed
    CPU
    I7 4970K OC'ed @4.7 GHz
    Motherboard
    MSI-Z97
    Memory
    16 GB G-Skill Trident X @2400MHZ
    Graphics Card(s)
    NVIDIA GeForce GTS 450
    Sound Card
    X-Fi Titanium Fatal1ty Professional Series
    Monitor(s) Displays
    Dual HP-W2408
    Screen Resolution
    1920X1200
    Hard Drives
    256 GB M2 sm951, (2) 500GB 850EVO, 5TB, 2 TB Seagate
    PSU
    Antec 850W
    Case
    Antec 1200
    Cooling
    Danger Den H20
    Keyboard
    Logitech
    Mouse
    Logitech Performance Mouse MX
    Internet Speed
    35/12mbps
    Browser
    Firefox
This: ReNamer - Download I use for many years now and is very versatile and fast. Can even do conversion capital <>small letters hash removal, numbering etc.
 

My Computer

System One

  • OS
    Windows 8.1 Pro
    Computer type
    PC/Desktop
    System Manufacturer/Model
    Home made
    CPU
    AMD Ryzen7 2700x
    Motherboard
    Asus Prime x470 Pro
    Memory
    16GB Kingston 3600
    Graphics Card(s)
    Asus strix 570 OC 4gb
    Hard Drives
    Samsung 960 evo 250GB
    Silicon Power V70 240GB SSD
    WD 1 TB Blue
    WD 2 TB Blue
    Bunch of backup HDDs.
    PSU
    Sharkoon, Silent Storm 660W
    Case
    Raidmax
    Cooling
    CCM Nepton 140xl
    Internet Speed
    40/2 Mbps
    Browser
    Firefox
    Antivirus
    WD
Bulk File Rename

Base on what you want to get done. Instead of using tedious DOS commands, you can download a free ware from the link below:
Bulk Rename Utility

Hope this helps !!!


Thanks, Topgun.

I set up a dummy folder and it worked a treat so it's ALMOST there.

I just need one more thing for it to do - Will it (to your knowledge) perform the "find and replace" function at folder level rather than the next level down in the tree which is the filename level. For each Author I have a folder for EVERY book, short story, graphic Novel, comic issue etc. Each Folder contains the same book in up to Five different file types.

In other words, can I say to it :-

"find all files which contain the text "Henry Rider Haggard" and replace that text with "". Look in the following Folders and perform this on any filename that meets the specified criteria".

If you know that it doesn't then you'll save me much time trying fruitlessly to find it.
If you know that it does, then I can search and try things to find out how.

If you don't know then, if I find it I'll let you know how.

Thanks again

Merlin
 

My Computer

System One

  • OS
    Win 8.1
    Computer type
    PC/Desktop
No help but now I understand what you were asking in the OP. Brings me back to my old dBASE programming days, it would handle what you are doing and then some.

Wow! They even have a new version out, it's still alive and well.
 

My Computer

System One

  • OS
    Windows 8.1 Pro 64-bit
    Computer type
    Laptop
    System Manufacturer/Model
    Acer V3 771G-6443
    CPU
    i5-3230m
    Motherboard
    Acer VA70_HC (U3E1)
    Memory
    8GB DDR3 PC3-12800 (800 MHz)
    Graphics Card(s)
    HD4000 + GeForce GT 730M
    Sound Card
    Realtek High Definition Audio
    Monitor(s) Displays
    17" Generic PnP Display on Intel HD Graphics 4000
    Screen Resolution
    1600x900 pixels
    Hard Drives
    Samsung SSD 850 EVO 250 GB
    ADATA SSD SP900 128GB
    PSU
    90 watt brick
    Mouse
    Bluetooth
    Antivirus
    Comodo
    Other Info
    Asus RT-AC56R dual-band WRT router (Merlin firmware). Intel 7260.HMWWB.R dual-band ac wireless adapter.
What do you mean there is no such thing as DOS ?

I was under the impression that DOS commands are still used in command prompt windows.


Merlin

You can run commands from the command prompt but it is not DOS, so some of the commands you used to run in DOS may not work or do something different from what you intended to do. You can call it a peeve, but some of us get annoyed when people refer to the command shell as DOS. Windows NT based operating system do not have DOS.
 

My Computer

System One

  • OS
    Windows 10 Education 64 Bit
    Computer type
    PC/Desktop
    System Manufacturer/Model
    Asus
    CPU
    AMD Phenom II X4 980 Black Edition Deneb 3.7GHz
    Motherboard
    ASUS M4N68T-M V2 µATX Motherboard
    Memory
    8GB 4GBx2 Kingston PC10600 DDR3 1333 Memory
    Graphics Card(s)
    NVIDIA Geforce GT640 2 Gig DDR3 PCIe
    Sound Card
    VIA VT1708s High Definition Audio 8-channel Onboard
    Monitor(s) Displays
    22" LG E2242 1080p and 2 19" I-INC AG191D
    Screen Resolution
    1280x1024 - 1920x1080 - 1280x1024
    Hard Drives
    Crucial MX100 256 GB SSD and 500 GB WD Blue SATA
    PSU
    Thermaltake TR 620
    Case
    Power Up Black ATX Mid-Tower Case
    Cooling
    Stock heatsink fan
    Keyboard
    Logitech Wireless K350 Wave
    Mouse
    Logitech M570 Trackball and T650 TouchPad
    Internet Speed
    80 Mbps Down 30 Mbps Up
    Browser
    Internet Explorer 11
    Antivirus
    Windows Defender
    Other Info
    HP DVD1040e Lightscribe - External USB2
Thanks, Topgun.

I set up a dummy folder and it worked a treat so it's ALMOST there.

I just need one more thing for it to do - Will it (to your knowledge) perform the "find and replace" function at folder level rather than the next level down in the tree which is the filename level.
Personally I don't use it. The best place to get the answer is click on 'Help' then Forum where they have questions, discussion etc...
 

My Computer

System One

  • OS
    8.1x64PWMC Ubuntu14.04x64 MintMate17x64
    Computer type
    PC/Desktop
    System Manufacturer/Model
    Home Brewed
    CPU
    I7 4970K OC'ed @4.7 GHz
    Motherboard
    MSI-Z97
    Memory
    16 GB G-Skill Trident X @2400MHZ
    Graphics Card(s)
    NVIDIA GeForce GTS 450
    Sound Card
    X-Fi Titanium Fatal1ty Professional Series
    Monitor(s) Displays
    Dual HP-W2408
    Screen Resolution
    1920X1200
    Hard Drives
    256 GB M2 sm951, (2) 500GB 850EVO, 5TB, 2 TB Seagate
    PSU
    Antec 850W
    Case
    Antec 1200
    Cooling
    Danger Den H20
    Keyboard
    Logitech
    Mouse
    Logitech Performance Mouse MX
    Internet Speed
    35/12mbps
    Browser
    Firefox
Thanks, Topgun.

I set up a dummy folder and it worked a treat so it's ALMOST there.

I just need one more thing for it to do - Will it (to your knowledge) perform the "find and replace" function at folder level rather than the next level down in the tree which is the filename level.
Personally I don't use it. The best place to get the answer is click on 'Help' then Forum where they have questions, discussion etc...

I've been using it for about 7 or 8 hours now and can't get it to do what I want, so I'm into trying to find a new library app that will work at the folder level and still read the filenames. Doesn't solve my problem with bulk change and replace though.

I shall return if I find a solution.

Thanks to all for the help

Merlin
 

My Computer

System One

  • OS
    Win 8.1
    Computer type
    PC/Desktop
If you're making all those changes merely because you're tight on space, I'd recommend that you get an external hard drive.

Here's part of a post from yesterday (private forum I belong to):

Hey guys and gals, I just got an email from Staples and a 750 GB Toshiba
External Drive is advertised for $49.99.

Perfect solution as far as I would be concerned. I have two interchangeable externals and am well pleased with them.
 

My Computer

System One

  • OS
    Windows 8.1
    Computer type
    PC/Desktop
    System Manufacturer/Model
    HP Pavilion 500-056
    CPU
    AMD Elite Quad-Core A8-6500
    Memory
    8 GB
    Graphics Card(s)
    AMD Radeon HD 8570D
    Monitor(s) Displays
    Acer 23"
    Screen Resolution
    1920 X 1080
    Hard Drives
    1 TB
    Keyboard
    Logitech Wave K350
    Mouse
    Logitech M510
    Internet Speed
    Fast
    Browser
    Firefox
    Antivirus
    Windows Defender
External Seagate

Thanks wynona.

By an amazing coincidences, I have a 3 Tb Seagate Wireless External Drive arriving tomorrow.

That will solve my physical space problems for the foreseeable future. Unfortunately it's not the whole story.

The people who scan Graphic Novels will insist on putting info like Artist, Writer, Date Published, Version No, Cover Variation and other stuff into the filenames not only of the Folder containing the Image Files, but into the Filename of every Image File within the RAR or CBR File that the folder contains.

You can't see these, so don't know that they've done it, until you extract the files of course and, even if the Reader works on the unextracted file, it still uses the FULL file name when you view it. You end up with multiple "Path name too long" errors and the programme freezes.

You also then get a problem with reading the names of individual Files in the bookshelf View because they only display a limited amount of text. which means that yiou have to actually open the Different episodes to find out which one you want to read next.

Back in the "Dream Time" I could write a set of instructions in DBase IV (Which was close to actually using plain language instructions), Test, Debug and Compile the list and have it run in background identifying duplicated extraneous rubbish and deleting it as the programme downloaded. Those days are gone, alas.

Ah well, never mind, just have to do it the hard way, I suppose.


Merlin
 

My Computer

System One

  • OS
    Win 8.1
    Computer type
    PC/Desktop
What do you mean there is no such thing as DOS ?

I was under the impression that DOS commands are still used in command prompt windows.


Merlin

You can run commands from the command prompt but it is not DOS, so some of the commands you used to run in DOS may not work or do something different from what you intended to do. You can call it a peeve, but some of us get annoyed when people refer to the command shell as DOS. Windows NT based operating system do not have DOS.

Here, Here!

I also get bugged by the misplaced "DOS" reference. Additionally, I hate when users refer to any text-based application or interface as "the old DOS program we used to use". I've heard the OS/2 Command Prompt, text-based OS/2 applications, terminal sessions on a mainframe through a telnet app, and even Unix text-based apps all referred to as "DOS".
 

My Computer

System One

  • OS
    Windows 8 x64 Professional
    Computer type
    PC/Desktop
    System Manufacturer/Model
    HP xw8600 Workstation
    CPU
    Two Intel Xeon Core2 Quad 3.2 GHz Processors
    Motherboard
    Proprietary
    Memory
    16 GB DDR2 800 MHz
    Graphics Card(s)
    nVidia Quadro FX 3800 PCI-E
    Sound Card
    Realtek HD Audio
    Monitor(s) Displays
    Samsung SyncMaster 213T 21" 4x3 Flat Screen
    Screen Resolution
    1600x1200
    Hard Drives
    Two Seagate Cheetah 300 GB SAS Disks
    PSU
    Proprietary
    Case
    HP xw8600 Workstation Case
    Cooling
    Two CPU Fans and a Larger Case Fan
    Keyboard
    PS/2 Keyboard
    Mouse
    Logitech USB Optical Mouse
    Internet Speed
    7 mbps
    Browser
    Firefox ESR 102
    Antivirus
    Windows Defender
    Other Info
    Two LSI 3000 SAS Adapters
What do you mean there is no such thing as DOS ?

I was under the impression that DOS commands are still used in command prompt windows.


Merlin

You can run commands from the command prompt but it is not DOS, so some of the commands you used to run in DOS may not work or do something different from what you intended to do. You can call it a peeve, but some of us get annoyed when people refer to the command shell as DOS. Windows NT based operating system do not have DOS.

Here, Here!

I also get bugged by the misplaced "DOS" reference. Additionally, I hate when users refer to any text-based application or interface as "the old DOS program we used to use". I've heard the OS/2 Command Prompt, text-based OS/2 applications, terminal sessions on a mainframe through a telnet app, and even Unix text-based apps all referred to as "DOS".

Well, Jody, You've got a hell of an uphill job on your hands reeducating all us poor uneducated types . Especially as I can see, on a quick and dirty search, over 300 Threads which talk aboiut the "DOS Command Prompt" and the "DOS Command Window".

Really, if you know what someone MEANS by the phrase they use, does it really matter whether they are TECHNICALLY correct. Many of us are not particularly interested in the ins and outs of the architecture of the computers we use or the way that things work on a chip level, we just want to know what button to click to get our fonts changed or our files in an acceptable order.

It's very comparable to the fact that I KNEW what you meant when you said "Here, Here" at the start of your post. The Phrase is actually "Hear, Hear" but you've probably never seen it written down.

However, for someone who is a student of the English Language, the words "Hear", "Here" and "Year" are all pronounced quite differently. But then, I'm pedantic about English.

But, as I knew what you MEANT by the misquoted phrase, I would never normally draw attention to it by correcting you - but on this occasion it does seem to be a good illustration of the fact that we Pedants all have our individual crosses to bear (LOL).

Merlin :):)
 

My Computer

System One

  • OS
    Win 8.1
    Computer type
    PC/Desktop
Merlin, at the risk of derailing this thread, I do agree with you. Proper English is dying. Here in the US if you correct anyone you're considered the "word police". We have really butchered the language.

Feel free to correct my post now. :)

EDIT: This is something we should discuss in the Chillout Room section. Don't get me started on they, their, and they're.
 

My Computer

System One

  • OS
    Windows 8.1 Pro 64-bit
    Computer type
    Laptop
    System Manufacturer/Model
    Acer V3 771G-6443
    CPU
    i5-3230m
    Motherboard
    Acer VA70_HC (U3E1)
    Memory
    8GB DDR3 PC3-12800 (800 MHz)
    Graphics Card(s)
    HD4000 + GeForce GT 730M
    Sound Card
    Realtek High Definition Audio
    Monitor(s) Displays
    17" Generic PnP Display on Intel HD Graphics 4000
    Screen Resolution
    1600x900 pixels
    Hard Drives
    Samsung SSD 850 EVO 250 GB
    ADATA SSD SP900 128GB
    PSU
    90 watt brick
    Mouse
    Bluetooth
    Antivirus
    Comodo
    Other Info
    Asus RT-AC56R dual-band WRT router (Merlin firmware). Intel 7260.HMWWB.R dual-band ac wireless adapter.
Back
Top