mkdir parameter hotfix
another fix for the permissin
order changed in insertfiles to match the measure log
clousure that used  removed
Inserfiles and algorithms checked