How can I create a random file using bash on Linux and how is it possible to delete a created file? I am not sure.
Idea: The user should enter an arbitrary file name and save it. They can also delete this saved file.
Thanks in advance
Code to delete a file:
if [ "$REPLY" = "d" ];
then
read -r -p 'Delete file: Please enter the name of the file to delete: ' -a delete_file
echo -e "\nFile was deleted: ${delete_file[*]}\n"
break
fi