Solved

run perl on an external drive

Posted on 2011-09-08
4
194 Views
Last Modified: 2012-06-27
Hi. I want to run this script on on files in H:\unrenamedFiles

I tried cd  H:\unrenamedFiles
but cannot seem to get out of the C drive.

The purpose of the script is to rename all the files in the directory.
Is there a way to do this on the external drive?
Thank you.
perl -e "rename $_,(/([^\d_]*)_?(\d*)-?(\d*)-?(\d*)_?([\d-]*)(.*)/,qq($4-$3-$2_$5_$1$6)) or warn qq($_ $!) for <tweets_*.csv> "

Open in new window

0
Comment
Question by:onyourmark
  • 2
  • 2
4 Comments
 
LVL 8

Expert Comment

by:pilson66
ID: 36501859
in console:

H:\
cd unrenamedFiles
0
 

Author Comment

by:onyourmark
ID: 36502197
Hi. I forgot to say this is windows.

'H:\' is not recognized as an internal or external command,
operable program or batch file.
0
 
LVL 8

Accepted Solution

by:
pilson66 earned 500 total points
ID: 36502214
start-->run-->cmd
H:
cd unrenamedFiles
0
 

Author Closing Comment

by:onyourmark
ID: 36502581
Thanks!
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Suggested Solutions

In the distant past (last year) I hacked together a little toy that would allow a couple of Manager types to query, preview, and extract data from a number of MongoDB instances, to their tool of choice: Excel (http://dilbert.com/strips/comic/2007-08…
Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now