How can I search a folder tree for files and folders whose names end with a space?

I am integrating our Macintoshes into our Windows network and file serving services.  In transferring files from one server to another, I'm coming across problem folders whose names end with a space--something easily handled on a Mac, but not in Windows at all.

How can I search and entire folder tree, in either OS X or Windows, for all files and folders whose names end with a space?

Dimarc67
New York, NY
LVL 4
Dimarc67Asked:
Who is Participating?
 
ozoConnect With a Mentor Commented:
find / -name '* '
0
 
Dimarc67Author Commented:
Thanks, Ozo.  But your simple answer made me realize that I didn't provide enough information.

The folder tree I need to search is a network share on a Windows server, though I can access it from either Mac or Windows clients.

Can a OS X command line command be used to search a server share?
0
 
AJViennaConnect With a Mentor Commented:
The shares appear under /Volumes after being mounted. E.g. by going there in the Finder.

Then you can open up a terminal and type:
find /Volumes/<YourShare> -name 't* '

use
ls /Volumes
to see your mounted shares.


0
 
ozoCommented:
yes
find /Volumes/sharename -name '* '
0
 
Dimarc67Author Commented:
Worked perfectly.
0
All Courses

From novice to tech pro — start learning today.