Mailinglist Archive: opensuse (3644 mails)

< Previous Next >
Re: [SLE] Putting the date in DD-MM-YYYY format into a variable
  • From: Anders Johansson <andjoh@xxxxxxxxxxxxxxxxxxxxx>
  • Date: Fri, 8 Mar 2002 13:38:01 +0100
  • Message-id: <200203081338.01496.andjoh@xxxxxxxxxxxxxxxxxxxxx>
On Friday 08 March 2002 13.12, Ray Booysen wrote:
Hi, I need to get the date in the above format into a variable so my backup
script can create a directory to store the archive in. any suggestions?

mkdir /var/backup/`date +%d-%m-%Y`

is one way to do it. I'm sure there are others

//Anders

< Previous Next >
References