save the command line history to header