Answers for "today's date shell script"

2

today's date shell script

#!/bin/bash
now="$(date)"
printf "Current date and time %s\n" "$now"
 
now="$(date +'%d/%m/%Y')"
printf "Current date in dd/mm/yyyy format %s\n" "$now"
 
echo "Starting backup at $now, please wait..."
# command to backup scripts goes here
# ...
Posted by: Guest on August-18-2020

Browse Popular Code Answers by Language