date cmd


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting date cmd
# 1  
Old 09-18-2008
date cmd

Hi all,

date +%d/%m/%Y

This is the command that displays current date(18/09/2008).
Now, is there a way that would give me yesterdays date..? or tomorrows date n things like that?
# 2  
Old 09-18-2008
If your date has the -d option, then yes. If not, see the FAQ.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Date: invalid date trying to set Linux date in specific format

i try to set linux date & time in specific format but it keep giving me error Example : date "+%d-%m-%C%y %H:%M:%S" -d "19-01-2017 00:05:01" or date +"%d-%m-%C%y %H:%M:%S" -d "19-01-2017 00:05:01" keep giving me this error : date: invalid date ‘19-01-2017 00:05:01' Please use CODE tags... (7 Replies)
Discussion started by: umen
7 Replies

2. Shell Programming and Scripting

Converting a date to friday date and finding Min/Max date

Dear all, I have 2 questions. I have a file with many rows which has date of the format YYYYMMDD. 1. I need to change the date to that weeks friday date(Ex: 20120716(monday) to 20120720). Satuday/Sunday has to be changed to next week friday date too. 2. After converting the date to... (10 Replies)
Discussion started by: 2001.arun
10 Replies

3. Shell Programming and Scripting

Perl open(CMD, "cmd |"); buffering problem..

Hello, There's a third-party application's command that shows the application's status like "tail -f verybusy.log". When use the command, the output comes every 1-sec. but when it goes in a script below the output comes every 8-sec...What is the problem and how can I fix it? open(CMD,... (2 Replies)
Discussion started by: Shawn, Lee
2 Replies

4. UNIX for Dummies Questions & Answers

How to Identify date of file backed up used FBACKUP cmd?

Dear UNIX Experts, I'm a newbie. My name is Budi. I need some help from any body in this forum. How do we identify the backed up date of file in the Back up tape ? I did the back up using FBACKUP cmd. I tried to googling it, but unfortunately no aimed solution that I got. :confused: I've... (0 Replies)
Discussion started by: Bhoed
0 Replies

5. Shell Programming and Scripting

Unix cmd prompt how to get old cmd run?

Hi, I am using SunOS I want to serch my previous command from unix prompt (like on AIX we can search by ESC -k) how to get in SunOs urgent help require. (10 Replies)
Discussion started by: RahulJoshi
10 Replies

6. AIX

Yesterday's date without changing anything and in one cmd line ?

I have seen references in the forum about getting yesterday's date but it is either by changing something in the system (date, time zone, ...) or with more then one line of script cmds. How can I get yesterday's date without changing anything in the system and in one single command line ? (4 Replies)
Discussion started by: Browser_ice
4 Replies

7. Shell Programming and Scripting

date with find cmd

Hi for today i have 10 files, in that i need search some values how can i write a find cmd with perticular date thanks SAIC (4 Replies)
Discussion started by: saic
4 Replies

8. Shell Programming and Scripting

want date in format eg:Nov 12 using date cmd

I want date in format eg: using cmd date then it show Dec 05 (2 Replies)
Discussion started by: RahulJoshi
2 Replies

9. Shell Programming and Scripting

Error with Date cmd

Hi all, When i execute the below command its giving an error "date: Bad conversion" date \"+DATE %m/%d/%Y HEURE %H:%M:%S\" (4 Replies)
Discussion started by: krishna_gnv
4 Replies

10. UNIX for Dummies Questions & Answers

man <cmd> >> cmd.txt

I've noticed most of my postings here are because of syntax errors. So I want to begin compiling a large txt file that contains all the "man <cmd>" of the commands I most have problems with. I ran a "man nawk >> nawk.txt" but it included a header/footer on each "page". Anyone know how I'd be... (6 Replies)
Discussion started by: yongho
6 Replies
Login or Register to Ask a Question