Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

OT: spaces in pathnames



Can anybody point me to a tutorial on how to write shell scripts that work even if supplied pathnames contain spaces?

Specifically, I have to pass an argument list from one program to another. It seems that I have to write the filenames to a file. Using ls -db, I can write the filenames with special characters fully escaped. The second program (invoked via open-x11) somehow needs to read these filenames. If I use $(<$FILENAME), the filenames get split at the spaces despite the backslashes, e.g. Isabelle\ app\ bundle becomes three words.

Any thoughts? Some hack using IFS?

Larry Paulson


_______________________________________________ Do not post admin requests to the list. They will be ignored. X11-users mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/x11-users/email@hidden

This email sent to email@hidden


Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.