In a nutshell i'm working with a program that uses JSCH and xstream to zip a file, and send it to a remote linux server. I'm using static folders, but when i send a file with the same name as one in the folder it will overwrite the exhisting file. I don't want this to happen. I can run pre and post scripts before and after the file is sent. How can i eliminate this, i was thinking returning a file with the list of files using ls and somehow storing that in a file. I'm curious of how someone else would do it as i'm trying to find the most efficient way.
Thanks