TechWhirl (TECHWR-L) is a resource for technical writing and technical communications professionals of all experience levels and in all industries to share their experiences and acquire information.
For two decades, technical communicators have turned to TechWhirl to ask and answer questions about the always-changing world of technical communications, such as tools, skills, career paths, methodologies, and emerging industries. The TechWhirl Archives and magazine, created for, by and about technical writers, offer a wealth of knowledge to everyone with an interest in any aspect of technical communications.
> The following command at the command prompt adds the current
> date to all
> jpg files in the current directory that begin with "pic":
>
> ren pic*.jpg "pic*%date:/=%.jpg"
>
> So:
>
> pic_pretty_sunset.jpg
> becomes
> pic_pretty_sunset.jpgThu 011509.jpg
>
> pic_ugly_politician.jpg
> becomes
> pic_ugly_politician.jpgThu 011509.jpg
>
> How could we turn that MMDDYY into YYYYMMDD, as David suggests below?
"txt" of course is whatever extension you want to change. Save this command
in a text file in the directory of the filenames to change and change the
extension "txt" to "cmd". Run the command file, <whatever you called
it>.cmd, from the command prompt. So for "test.cmd", enter "test" after the
command prompt.
You should notice that the number after the tilde refers to the character
position in the date string and the number after the comma is the number of
digits before that position. UNIX is so much better at handling strings and
scripts.
ComponentOne Doc-To-Help 2009 is your all-in-one authoring and publishing
solution. Author in Doc-To-Help's XML-based editor, Microsoft Word or
HTML and publish to the Web, Help systems or printed manuals. http://www.doctohelp.com
Help & Manual 5: The complete help authoring tool for individual
authors and teams. Professional power, intuitive interface. Write
once, publish to 8 formats. Multi-user authoring and version control! http://www.helpandmanual.com/
---
You are currently subscribed to TECHWR-L as archive -at- web -dot- techwr-l -dot- com -dot-