date command is used to display the system date and time. date command is also used to set date and time of the system. By default the date command displays the date in the time zone on which unix/linux operating system is must be the super-user (root) to change the date and time.
Date Command in Linux | Linuxize
$date 8775 +%Y-%m-%d 8776
%Y is keyword for four digit year
%m is keyword for two digit month
%d is keyword for two digit date
Hyphen is separator here.
Datetime - subtract 1 hour from date in unix shell script
I have the basic idea that I have to move the file date + 8776 %d%m%Y 8776 .csv to my destination folder. But not able to do it. Or rather, I do not know how to do it. Please help.
That worked, but it is ugly. No problem, we can include spaces as long as we wrap the entire format string in quotation marks. Note that the + goes outside the quotation marks.
Options with Examples
6: date (no option) : With no options, the date command displays the current date and time, including the abbreviated day name, abbreviated month name, day of the month, the time separated by colons, the time zone name, and the year.
To use any of the options type date , a space, a plus sign + , and the option including the leading percentage sign. The %c (data and time in locale format) option causes the date and time to be printed in the normalized format associated with your locale. Your locale is set by the geographical and cultural information you provided when you installed your operating system. The locale governs such things as the currency symbol, paper sizes, timezone, and other cultural norms.