A simple syntactical question may be
While trying to display the date in my custom format, i am using
date '+DATE %m-%y%nTIME %H:%M:%S'
What is the purpose of ‘+’ symbol before specifying Date format ?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The
+tells date that you want it to be in that format. From the man page:Otherwise, date thinks you are trying to send it a date string (
[MMDDhhmm[[CC]YY][.ss]]), not a format string.