Some reorganization of the scripts