Hi,
I am trying to perform a dos2unix conversion for a file. I am doing this in the FOR loop. Below is the command I am using in my script.
$FILE is the file the for loop is processing currently and I would like to convert $FILE and create a $FILE_I
PHP Code:
dos2unix -n $WORK/$FILE $WORK/$FILE_I
This is not working.. it throws an error that it can't convert the $file and it is creating a dummyfile something like this d2utmpPuto7N and d2utmpaiOzz6 and writing it to that file instead of $FILE_I
should I create a $FILE_I file before executing this dos2unix command or a file called $FILE_I can't be created in the FOR loop??
I have to create such file as the file names, file numbers to be processed all are dynamic.
I also tried copying the $FILE to $FILE_I before dos2unix command but no luck, the error is $FILE and $FILE_I both are same cannot copy...
Can someone throw some light on what is missing?
Thanks!