Add a flattening script.