Carrying Terminal History Across Devices#
Recently at work I received a new device, and around the same time I bought a new machine for personal use. While setting them up, I realized how important it is to have my terminal history carried over. Some of my commands are very long and contain context that I do not want to retype from scratch.
My first thought was to copy the .zsh_history
file from the old machine to the new one. That works, but it is not the most efficient way to sync terminal history, especially when using multiple devices.
This led me to discover Atuin. Atuin is a tool that allows you to sync your terminal history seamlessly across all your machines. It is open source, free forever, and it encrypts your data. The best part is that it integrates with your existing shell configuration, so you can start using it right away without changing your workflow.
While setting up multiple machines, I also decided to finally invest time into automating my setup as much as possible with chezmoi. That deserves its own write-up, which I will cover in a future post.