Fix realpath of the scripts