Originally posted by Gavin:
I'm not a UNIX shell guru but I play one on TV.
You can replace all the date stuff with one line:
set thedate = `date '+Gathered Items (%a, %b %d, %Y %I:%M:%S %p)'`
I think %I and %p will do what you want. See man strftime
if only man date SHOWED the %I and %p options grr...... hahaha
the main reason I split it up was I needed to if then $thehour and I could not if all the date and time were
in one var. I could NOT find all the formats options so I was forced to split it up but strftime shows them all.
YEAH! so I can dump the splitting and if then stuff. cool
Originally posted by Gavin:
To place several commands on one line separate them with semicolons.
So, try playing around with this:
set new_dir = `date '+Gathered Items (%a, %b %d, %Y %I:%M:%S %p)'`; mkdir __OBJ_COMMON_PARENT_PATH__"$new_dir"; mv __OBJ_PATH__ __OBJ_COMMON_PARENT_PATH__"$new_dir"
LOL with the better formating for date and no need for if then etc.... very easy to get on one line.
You think it is possible if you had to in case in the future one needed to get all that on one line?
I mean I got lucky here because %I and %p solved the problem but there may come a time when
a script snippet might have to be combined
Anway thanks, this fixes everything
