add config and fromfile tofile