shared code to single files