#!/bin/bash

if [ $# -ne 1]; then
    echo "Provide only 1 parameter"
    exit 1
fi

filename=$1

if [ ! -f "$filename" ]; then
    echo "$filename no exist"
    exit 1
fi

current_date=$(date +%d%m%Y)

new_filename="${filename}.${current_date}"

cp "$filename" "$new_filename"

echo "File copied to $new_filename"