Article 524QB Need help with script to copy files from hfs+ (read-only) to ntfs (some chars not allowed)...

Need help with script to copy files from hfs+ (read-only) to ntfs (some chars not allowed)...

by
wallphoenix
from LinuxQuestions.org on (#524QB)
I have some recovered files on an hfs+ drive (which is journaled, so I can only mount it read-only), that I need to copy to an ntfs drive so they can be accessed from a friend's windows machine. Unfortunately, there are a number of files with characters in the filenames that are allowed in hfs+, but not windows, so I need to batch rename them before they can be written to the ntfs drive, but without writing on the read-only drive.

My current thought is to use rename's -n option, which prints a list of files that will be renamed to stdout, and use that list with copy to change the name of each of those files.

Can someone help me out with what commands might be needed to send info from that list to copy for the right file in each case? Or is there a better/safer way to do this?

Thanks!latest?d=yIl2AUoC8zA latest?i=2zTscnC8o68:KYa1c4QdpMA:F7zBnMy latest?i=2zTscnC8o68:KYa1c4QdpMA:V_sGLiP latest?d=qj6IDK7rITs latest?i=2zTscnC8o68:KYa1c4QdpMA:gIN9vFw2zTscnC8o68
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments