improved script backup