Hello,
I have a script that gets files from a path. (this script works perfectly)
I would like to extract the iso fiels to a path I need to give the script.
Is it possible? and how?
This is my script:
def list = []
//get iso files
def dir = new File("xxxx/xxx/xxxx/xxxx"+issue.getSummary()+"/yyyy/yyyy")
dir.eachFileRecurse (FileType.FILES) { file ->
list << file
}
for(def i=0;i<list.size();i++)
{
boolean flag=true;
def z=list[i].toString().length();
def counter=0;
while(list[i].toString()[z-1]!='/')
{
counter++;
z--;
}
def summary = list[i].toString().substring(list[i].toString().length()-counter,list[i].toString().length());
log.warn summary;
//file inside ends with iso
if(summary.toString().endsWith("iso"))
{
EXTRACT THE ISO FILE TO SPECIFIC PATH
}
Thank you