add appendOnFile feature