updated history to save cd commands