trim scripts