--On October 13, 2005 4:04:45 PM -0700 Drew Tomlinson <[EMAIL PROTECTED]> wrote:

I'm working on a script that reads a directory using 'find' and its
'-exec' primary to create a symlink to the file.  So for example, I have
the following command:

find /multimedia/Pictures -iname "*.jpg" -print | cut -d'/' -f4

You'll have to play with the field value (-f) to get the right location, but this would return only the filename.

This command returns a bunch of filenames.  Here's an example of one:

/multimedia/Pictures/2005 Kimberly & Rich/IMG_1210.JPG

What I'd like to is get '-exec' to run this command:

I don't understand what you're trying to do here.

ln -s "/multimedia/Pictures/2005 Kimberly & Rich/IMG_1210.JPG" "2005
Kimberly & Rich/IMG_1210.JPG"

Are you trying to create symlinks in a different directory? If so, why not do this?

ln -s dir1/ dir2/

Then, when you add new files to dir1/ they will automatically show up in dir2/ because the dir is symlinked rather than the individual files.

What exactly are you trying to accomplish?

Paul Schmehl ([EMAIL PROTECTED])
Adjunct Information Security Officer
University of Texas at Dallas
AVIEN Founding Member
http://www.utdallas.edu/
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Reply via email to