I would like to write a script which will test the existence of a file and
there creation date (file creation to day).
- If the file is present and creation to day, the programm continuous (Code
- If the file is not present, the program stops (code return 1).
- If the file is present but the current date does not carry, the program
stops (code return 2)
But I have difficulty to transform into code the test of the file and date
of his creation.
Here my script. Thanks for helping me to make it achievable
Thank you to correct my script because it does not good.
# "mapasa" c'est le nom de mon fichier
if [-f file ] and [file (created to day)]"; then echo "file exist and the
if [!-f mapasa] then echo "file not exist"
if [-f mapasa] and [file (created to day] then echo "file is an old file"
Thank you for your assistance