Print out command history...

Hi Opensuse People,

I was just wondering how you print out the history of all the commands you entered at a terminal and append to a file…


Simple and non-elegant: history > myhistory.txt :wink:

edit: if you want to append use two pipes; history >> myhistory.txt

Thanks very much… :slight_smile:

that’s not a pipe, it’s a redirector :wink: that’s a pipe: |

hehehe… true, good thing I never post these things where others can read it.


history command reads ~.bash_history file. U can use this file too.