fix argument handling when cm / cmi is invoked in a symlinked folder (#638)