Date: Thu, 13 Oct 2005 20:43:02 -0500 From: Kirk Strauser <kirk@strauser.com> To: freebsd-questions@freebsd.org Subject: Re: sh Scripting - String Manipulation Message-ID: <200510132043.06169.kirk@strauser.com> In-Reply-To: <434EE80D.2010103@mykitchentable.net> References: <434EE80D.2010103@mykitchentable.net>
next in thread | previous in thread | raw e-mail | index | archive | help
--nextPart1650692.JqiNb8un7X Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On Thursday 13 October 2005 06:04 pm, Drew Tomlinson wrote: > What I'd like to is get '-exec' to run this command: > > ln -s "/multimedia/Pictures/2005 Kimberly & Rich/IMG_1210.JPG" "2005 > Kimberly & Rich/IMG_1210.JPG" The easiest way I've found is to simply change into /multimedia/Pictures=20 before running find, then refer "ln" back to your original directory. Say that you want the links to be made inside /home/drew . Instead of runn= ing=20 find from their, do: $ cd /multimedia/Pictures $ find -iname '*.jpg' -exec ln -s {} /home/drew There - you've removed any need for string manipulation with a simple cd. =2D-=20 Kirk Strauser --nextPart1650692.JqiNb8un7X Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQBDTw0q5sRg+Y0CpvERAv8HAJ0XXR8ICTRWElLaPVyousBcw6dZqgCghUdj cde0UOUME+36SlRAW6XtUD8= =SlIu -----END PGP SIGNATURE----- --nextPart1650692.JqiNb8un7X--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200510132043.06169.kirk>