I am very new to linux so please explain things to me like I was not from this world. I never wanted to learn linux, but since the other IT person is gone, I was the only one left. So now I have been messing around with it alot, and I really like it. Bought a few books, and CBT's to get use to it, and I absolutely love it, though my games don't work, I can live without them for now.
Anyways, I am making a script to decrypt a file and then send an email when done. The thing is I want to keep this as close to automatically as possible. So the next person won't need to fuss about the long process of our loads.
So my first problem is displaying the files with certain credentials, then moving all previous files to a backup folder. Our clients sometimes sends us two files, but the latest one is the one we need to process. But I can not even get this program to display all the files.
Then after displaying it move the old files to backup and only have the newest file.
I have this so far:
#!bin/bash
# Check directory for all rabadd*.gpg
if [ -e /home/eacsci1/rabadd*.gpg ]; then
echo "rabadd encrypted file(s) exist"
\# Locate and display files with name rabadd and ext .gpg. Then clear when done.
find -maxdepth 1 -name rabadd*.gpg > rabadd.txt ; cat rabadd.txt ; rm rabadd.txt.
# In case the encrypted file does not exist, let user know.
else
echo "rabadd encrypted file(s) not found!"
fi