LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   date command (https://www.linuxquestions.org/questions/linux-newbie-8/date-command-4175495029/)

sryzdn 02-15-2014 10:55 AM

date command
 
Hi,

What does this command represent:

Quote:

$ date +%d/%m
Thanks for your help.

Isaac Velando 02-15-2014 11:04 AM

GNU date is used to interact with the system's date and time; for one example it's very useful in scripting for adding dates and/or times to file names. Anyway I advise you to consult the manual to get a full listing of its capabilities including what %d/%m means (see the FORMAT section) -- there's such a wide array of capabilities you'd be doing yourself a disservice by not checking them out.

Code:

man date
and use either arrow keys and page up/page down or vim style d, u, j, k to navigate.

273 02-15-2014 11:11 AM

Quote:

Originally Posted by sryzdn (Post 5118225)
Hi,

What does this command represent:



Thanks for your help.

Did you run it and see what the result was? What does it look like it represents?

sryzdn 02-15-2014 11:29 AM

Quote:

Originally Posted by 273 (Post 5118232)
Did you run it and see what the result was? What does it look like it represents?

yes, I swear I'm not that lazy to run the command. But it only shows today's date. So what's the use of all +%d/%m ?

273 02-15-2014 11:31 AM

I mean what precisely does it show and how does that relate to what you typed in?

sryzdn 02-15-2014 11:37 AM

Quote:

Originally Posted by Isaac Velando (Post 5118229)
GNU date is used to interact with the system's date and time; for one example it's very useful in scripting for adding dates and/or times to file names. Anyway I advise you to consult the manual to get a full listing of its capabilities including what %d/%m means (see the FORMAT section) -- there's such a wide array of capabilities you'd be doing yourself a disservice by not checking them out.

Code:

man date
and use either arrow keys and page up/page down or vim style d, u, j, k to navigate.

I got it thank you


All times are GMT -5. The time now is 06:23 AM.