auto find template in m2d/../templates