I'm now refining my scripts which are providing me useful information. I successfully do something like:
S3CMD="/usr/bin/s3cmd sync -v --delete-removed" (to set up options for s3cmd once) $S3CMD /path/to/source /path/to/destination/ (to run s3cmd with the above options). Attempts to combine the "time" options in a similar way give me trouble, if I try something like: S3CMD="/usr/bin/s3cmd sync -v --delete-removed" TIME="/usr/bin/time -f '%E %x %C'" $TIME $S3CMD /path/to/source /path/to/destination/ I would get errors indicating time or s3cmd usage issues (depending on various random attempts at getting single or double quotes in the right place). The following works OK: /usr/bin/time -f '%E %x %C' $S3CMD /path/to/source /path/to/destination/ Hopefully I am demonstrating the issue sufficiently and someone can indicate where my syntax needs attention to be able to do a "$TIME $S3CMD" version? Explanation of why is optional but I will attempt to understand if provided. Cheers, Roger On 24/05/11 11:34, Roger Searle wrote: > Thanks very much for all the responses, more than sufficient for playing > with. > > Cheers, > Roger > > > On 24/05/11 10:37, Jim Cheetham wrote: >> jim@hex:~/tmp$ /usr/bin/time -f '%E %x %C' sleep 5 >> 0:05.00 0 sleep 5 >> >> I think you'll find something to keep you amused in that lot ... >> >> -jim >> _______________________________________________ Linux-users mailing list [email protected] http://lists.canterbury.ac.nz/mailman/listinfo/linux-users
