Automating mounting of ISO images
Chuck Swiger
cswiger at mac.com
Wed Mar 23 21:25:16 UTC 2011
On Mar 23, 2011, at 2:21 PM, Polytropon wrote:
> Prefix it with a test:
>
> [ -d /mount/office_files/images/${DEST} ] && mkdir...
> mount...
>
> so there will be no error if the script is started for the
> second time (and the directories still exist), means: create
> them only if not yet present.
While I agree with this suggested change from the perspective of only doing work if you actually need to do it, note that "mkdir -p" doesn't return an error if the directory already exists. :-)
Regards,
--
-Chuck
More information about the freebsd-questions
mailing list