Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I‘ve been doing this ever since I migrated from Windows to Mac in 2015. My bash history has over 40k lines, datestamped. I can recall any command I have typed in my terminal in the past seven years. Extremely helpful whenever I need to repeat anything in the terminal.

# Edit

I sometimes add comments to commands via `# This‘ll do this and that` so that I can find the command by those keywords in the bash history.



This. I've been doing this for a couple of years now, I'm really used to it. I've been "traveling" with my history that is over 70k lines. My dot alias file has only 3 aliases (c=clear, q=exit, gti=git).

Hope there's a project out there that helps parse, rank, or do something with a file like this. There must be interesting information.


Is gti=git for capturing typos or some other reason?


It's a typo, but I make it a lot!


Maybe I'm doing something wrong, but my bash history is missing many of my commands. I assumed it was due to poor handling of multiple open terminal windows and tabs.

Is there something you are doing so the different sessions don't clobber each other?




Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: