tidying up scripts