script almost ready (again)