LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Question about date (https://www.linuxquestions.org/questions/linux-newbie-8/question-about-date-103725/)

Leffe13 10-14-2003 04:25 AM

Question about date
 
I want to display the date like this

Date: 14/10/03
Time: 11:24

I know that I can put the date on the screen by date +%D%n%T But how can I put the string on screen.

It's for a shell script

Thanks
:newbie:

aqoliveira 10-14-2003 04:41 AM

Howzit

Place that string under the /etc/bashrc file like this:

alias date='date +"DATE: %D%nTIME: %T "'

This will be used for all users on your box.

chow


All times are GMT -5. The time now is 08:23 PM.