Inside a directory, there are 150 files named like
ABLIMITS.TXT. How do I rename them to
ABLIMITS_date.txt prompting the user for date?
Your question is a little unclear (how can 150 files in a single parent dir all have the same filename?), so here is an example of doing it with a single file named
In a POSIX shell:
Using the current date
Prompting the user for a date
I'm going to assume that you want to take the user input, and make sure it follows a standard format (e.g. YYYY-MM-DD). So let's try something like this:
You can read the man page for date to get more information on the format.