Date: Sun, 14 Jun 1998 09:58:03 -0700 (PDT) From: Ken McGlothlen <mcglk@serv.net> To: questions@FreeBSD.ORG Subject: Re: Unix commands Message-ID: <199806141658.JAA24308@ralf.serv.net>
next in thread | raw e-mail | index | archive | help
drifter@stratos.net (drifter@stratos.net) writes: | On Sat, Jun 13, 1998 at 09:04:59AM -0500, Dave Bender wrote: | > One solution would be: | > | > $ date | awk '{print "mv yourfile $2.html"}' | sh | > [...] | | How about: | | $ mv yourfile `date | awk '{print $2$3-$4.html}'` | | or alternatively: | | $ mv yourfile $(date | awk '{print $2$3-$4.html}') | [...] You know, the FreeBSD date command does support a strftime capability, so it might be more straightforward to write mv yourfile `date "+yourfile.%m"` ---Ken To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199806141658.JAA24308>