I've been using Atuin for at least a year and a half, and I think it's definitely the tool I'd been looking for the most in my entire dev career. It has made me much more confident with my hazy memory. Before it I'd struggle consistently to remember most of my recent commands.
bck-i was always a bit obtuse to me and I honestly never grokked it until I had Atuin wired into my workflow (hard) and ran into bck-i instead when SSH'd.
Anytime a peer views my screenshare, they ask "what's the funny thing that makes you so fast". I then proceed to share, first and foremost, Atuin.
Thanks Atuin team! Would love to contribute someday with more time.
One of the things I really struggle to retain about the shell is the various expansions.
Unfortunately history shows the expanded form of what's happened, so I can't go reference that I used the third word of history item 773 as an argument, I only see the resolved argument.
Alas I haven't found any hooks in zsh that show promise here. I'd really love the pure history.
One technique I've used in the past is making a quick command in vim, that takes the selection or current line, and sends it to a given terminal. And perhaps starts a new line too. Basically using vim to author commands, to build the history log. Also I get to use vim, yay.
I second this wholeheartedly. Atuin is a joy to use and makes it so easier to find past commands. Thanks a lot atuin, and thanks to the colleague who recommended it!
For zsh users who like this idea and don't want to have to worry about anything leaving the device (not to insinuate that Atuin is doing anything below board, I don't think they are) I built my own version of this for myself called raven:
Raven has no sync component, stores your history in a sqlite, and never tries to move data off the device. It has a similar / large overlap in features with Atuin.
Sharing here in case anyone else could benefit from it, it only supports zsh for the moment since that's what I use.
I am happy Atuin user now, but I was initially worried that it would sync my data unless I explicitly disabled that feature. The fact that it's opt-in becomes clear once you read the docs and understand how it works, but it might be worth emphasizing that on the landing page. Currently it says:
Shell history sync
Sync your shell history to all of your machines, wherever they are
this is my only quip with atuin, despite my endorsement in a sibling comment.
this should absolutely be opted-out BY DEFAULT. not defaulted to opt-in.
if you have someone outright cloning your entire project just to skip this opted-in privacy gap feature, it's a good indicator it's an issue to be mindful of!
Opt-in means that the user needs to actively decide to use the feature, it's OFF by default. That's currently the case for atuin (happy user without sync here).
Opt-out would mean the feature would be ON by default and users would need to actively decide NOT to use it.
I see it also supports fish. That's been my shell for many years, it just works really well and, as far as I can tell (couldn't find a demo on their website), it doesn't add much to fish beyond syncing?
Has anyone used fish + autuin? What are your thoughts? I'm curious to know if it is worth the extra tool, maybe I should just try it :)
I use fish + atuin. I leave the "Up" arrow set to use fish's default history search (see https://docs.atuin.sh/faq/#how-do-i-remove-the-default-up-ar...), which keeps the UI minimal when just going back one or two commands, then use atuin via Ctrl+R when I need to find a command from earlier in my history. At that point Atuin provides a nicer UI for searching the history.
I've been using fish + atuin for well over a year now. I personally love it. I'm not sure if zsh or bash with atuin offers some additional features that fish doesn't, but the shell syncing and fuzzy search is enough of a value that it made it completely worth setting up for me.
fish doesn't use SQLite, but its own plaintext format. They've been trying to migrate to other formats.[1] Currently fish stores timestamps and directories in its history.
If any of you is having problems with Atuin acting weirds or slow, and has a ZFS filesystem, there's a known problem with sqlite and ZFS [0]. There are a couple of workarounds [1] that are, either using `atuin daemon`, or creating an ext4 volume for the atuin storage.
If I explicitly DON’T want sync between machines (my workflows are very machine specific), does atuin give me anything significant over my current fzf based C-r?
I don't use the sync feature, but I will say that "my workflows are very machine specific" is one of the reasons I use Atuin. When working in containers, I sometimes share an Atuin database volume between them, to save history relevant to those containers.
On MacOS the main reason I reach for Atuin is that I have never been able to get ZSH to store history properly. Atuin saves history to SQLite, which so far has been much more reliable. It also enables some nice features like being able to search commands run from the same directory.
> does atuin give me anything significant over my current fzf based C-r
I'm interested in this as well. I currently use fzf and I'm happy with what I've got (except for me syncing would probably be a nice feature to have).
Also: I gave atuin a quick try and found the TUI to be worse than fzf. Why do I need a fullscreen ctrl-r interface? I found that distracting. But maybe that is configurable. I didn't look much further.
But the inline_height seems to be a constant, rather than a percentage of the window, which is weird.
As long as you're here, do you know if the column showing the amount of time the command took can be removed? I know you can remove it from "atuin history list" with history_format, but I don't see a way to remove it from the inline window.
Atuin has been a part of my dotfiles install.sh for the last two years. It became such an integral part of my flow that it became invisible. Prob not a good thing for them, but also a testament to how naturally it fits in.
I'm glad that there already is a tool that I was about to make. I don't usually like to change my workflow, but this seems like a very useful addition, since I can also add my history from past installations.
Is there a way to change the key binding of the search screen? I'm too attached to using the up key to recover the last command I used, and it's a little jarring to now have to click tab from the Atuin search interface. It adds a little friction each time I have to do this.
As an aside, most of my usage of history is to use the last few commands I used, and so seeing the entire history each time seems like an overkill.
I have been storing shell history in SQLite since 2017 [1]. I have always been a heavy shell user, with the worst memory. So having all the history stored and backed up was very useful for me. At the time when I became a full-time macOS user, I built a ShellHistory app for macOS [2], with full-text search, notebooks, and sync over iCloud (with advanced data protection [3]).
I tried to contact Atuin authors to see if I could also integrate ShellHistory with their servers, but at that time it seemed like they did not support third-party clients, and the API was not documented.
I highly recommend using tools like Atuin and ShellHistory, at this point I have 136,000 records since 2017. My shell history is the best documentation for me. If I need to do a `kubectl --raw` API call, and don't remember exactly how to write it, I just search for `kubectl raw` and get some results from the history, don't remember some advanced `git rebase`, just search the history for it.
I have been using it for over 6 months self hosted, best feature is to be able to sync between all my machines. Really good to replicate my rsync across servers. And nothing leaves my private infrastructure. A breeze with docker.
The sync feature is great, though there are many oddities with search sort order, unnecessary terminal cleanups, odd timeouts, etc. In some aspects it's a big upgrade from fzf, in some aspects it's a downgrade.
The sort order is strange, I agree. I forked Atuin awhile back with the goal of adding more strategies, but it was tougher than I expected. IIRC, changing search order involves updating both the DB queries and how the application code interacts with them.
I'd never sync my shell history with a third party. The self-hosting option looks interesting, but anyone comfortable with syncing their shell history with a third party is severely lacking basic privacy literacy and underestimates the sensitivity of command history.
You can use atuin without syncing it between multiple machines.
I have my shell environments divided up into different distrobox containers. Some of them sync between multiple machines. Some of them don't. Depends what the shell is for.
I recently switched to Atuin from McFly, and while McFly has been a solid performer for me for years, I love Atuin. Worth pointing out for others who care about such things as it's not made clear on this landing page, you don't actually need to register - if you don't need the sync, you can just use it without registering and it's still amazing, and if you do need the sync but don't like the idea of your history being stored on someone else's server, you can self-host the sync server too.
I've been using Atuin for at least a year and a half, and I think it's definitely the tool I'd been looking for the most in my entire dev career. It has made me much more confident with my hazy memory. Before it I'd struggle consistently to remember most of my recent commands.
bck-i was always a bit obtuse to me and I honestly never grokked it until I had Atuin wired into my workflow (hard) and ran into bck-i instead when SSH'd.
Anytime a peer views my screenshare, they ask "what's the funny thing that makes you so fast". I then proceed to share, first and foremost, Atuin.
Thanks Atuin team! Would love to contribute someday with more time.
(dev here!) thank you so much! I love to hear things like this <3
I hadn't heard of this until just now, and I already can't imagine living without it. Thank you!
Thanks a lot for your work!
now please give us the cloud history feature opt-out by default please please. cheers
You already have it
Nothing syncs without you registering an account or logging in
lovely. I vaguely remember back when I first signed on, it wasn't opt-out by default so I assumed it stayed the same. disregard my quip! hahaha
I don't mean to be rude but this has been the case since the project first started in 2021. You have always had to sign in to sync anything at all
It's always been opt-in, or "opt-out by default".
did you even try to read the web page documentation? or the previous answer to that same question you asked? it doesn't send anything by default...
it could've been back in the day when I first installed it. glad to have it resolved tho. take it easy man
One of the things I really struggle to retain about the shell is the various expansions.
Unfortunately history shows the expanded form of what's happened, so I can't go reference that I used the third word of history item 773 as an argument, I only see the resolved argument.
Alas I haven't found any hooks in zsh that show promise here. I'd really love the pure history.
One technique I've used in the past is making a quick command in vim, that takes the selection or current line, and sends it to a given terminal. And perhaps starts a new line too. Basically using vim to author commands, to build the history log. Also I get to use vim, yay.
I second this wholeheartedly. Atuin is a joy to use and makes it so easier to find past commands. Thanks a lot atuin, and thanks to the colleague who recommended it!
For zsh users who like this idea and don't want to have to worry about anything leaving the device (not to insinuate that Atuin is doing anything below board, I don't think they are) I built my own version of this for myself called raven:
https://github.com/tylersaunders/raven
Raven has no sync component, stores your history in a sqlite, and never tries to move data off the device. It has a similar / large overlap in features with Atuin.
Sharing here in case anyone else could benefit from it, it only supports zsh for the moment since that's what I use.
Atuin is great though!
our sync is opt-in + optional, e2e encrypted, and self-hostable.
if that's not enough, you can disable all network features via a feature flag at compile time
if you don't care for sync, there are a bunch of other projects doing this (and supporting several shells), eg:
- mcfly: https://github.com/cantino/mcfly
- resh: https://github.com/curusarn/resh
I am happy Atuin user now, but I was initially worried that it would sync my data unless I explicitly disabled that feature. The fact that it's opt-in becomes clear once you read the docs and understand how it works, but it might be worth emphasizing that on the landing page. Currently it says:
In any case, thanks for building a great tool!> if that's not enough, you can disable all network features via a feature flag at compile time
Are there network features other than sync?
this is my only quip with atuin, despite my endorsement in a sibling comment. this should absolutely be opted-out BY DEFAULT. not defaulted to opt-in.
if you have someone outright cloning your entire project just to skip this opted-in privacy gap feature, it's a good indicator it's an issue to be mindful of!
I think you might be mixing them up?
Opt-in means that the user needs to actively decide to use the feature, it's OFF by default. That's currently the case for atuin (happy user without sync here).
Opt-out would mean the feature would be ON by default and users would need to actively decide NOT to use it.
You actually have to go and register an account or log in for sync to happen at all
Otherwise it’s offline, by default, right after install
Isn't it off by default? That's what opt-in means as far as I know.
For people OK with syncing to their own server, Atuin can be self-hosted as well
https://docs.atuin.sh/self-hosting/server-setup/
you could just disable sync in atuin
You could also just not enable it. It's off by default
I see it also supports fish. That's been my shell for many years, it just works really well and, as far as I can tell (couldn't find a demo on their website), it doesn't add much to fish beyond syncing?
Has anyone used fish + autuin? What are your thoughts? I'm curious to know if it is worth the extra tool, maybe I should just try it :)
I use fish + atuin. I leave the "Up" arrow set to use fish's default history search (see https://docs.atuin.sh/faq/#how-do-i-remove-the-default-up-ar...), which keeps the UI minimal when just going back one or two commands, then use atuin via Ctrl+R when I need to find a command from earlier in my history. At that point Atuin provides a nicer UI for searching the history.
I've been using fish + atuin for well over a year now. I personally love it. I'm not sure if zsh or bash with atuin offers some additional features that fish doesn't, but the shell syncing and fuzzy search is enough of a value that it made it completely worth setting up for me.
The main thing would be opt-in syncing, and I think we might store a little more context than fish does in their SQLite!
Otherwise consistency is nice if you use a few setups
fish doesn't use SQLite, but its own plaintext format. They've been trying to migrate to other formats.[1] Currently fish stores timestamps and directories in its history.
[1] https://github.com/fish-shell/fish-shell/issues/3341
If any of you is having problems with Atuin acting weirds or slow, and has a ZFS filesystem, there's a known problem with sqlite and ZFS [0]. There are a couple of workarounds [1] that are, either using `atuin daemon`, or creating an ext4 volume for the atuin storage.
--
I can't remember what my terminal was like before this. It's so fast, seamless and part of my day to day workflow. Solid open source project.
And don't forget to do :
`workspaces = true`
in your config, to limit your history to the current git repo.
Thank you very much atuin team. Can't work without atuin installed.
If I explicitly DON’T want sync between machines (my workflows are very machine specific), does atuin give me anything significant over my current fzf based C-r?
Atuin stores much more context than ctrl-r does - exit codes, command duration and directory, etc
Also has functions for filtering command search by directory
Being backed by SQLite tends to mean your history is more durable + is properly saved across shells too
Ability to change the search mode (prefix, full text, fuzzy), and filter by path/host, time range, exit code, current session only, and more
I have been a reluctant adopter of Atuin.
I don't use the sync feature, but I will say that "my workflows are very machine specific" is one of the reasons I use Atuin. When working in containers, I sometimes share an Atuin database volume between them, to save history relevant to those containers.
On MacOS the main reason I reach for Atuin is that I have never been able to get ZSH to store history properly. Atuin saves history to SQLite, which so far has been much more reliable. It also enables some nice features like being able to search commands run from the same directory.
> does atuin give me anything significant over my current fzf based C-r
I'm interested in this as well. I currently use fzf and I'm happy with what I've got (except for me syncing would probably be a nice feature to have).
Also: I gave atuin a quick try and found the TUI to be worse than fzf. Why do I need a fullscreen ctrl-r interface? I found that distracting. But maybe that is configurable. I didn't look much further.
It is configurable!
And also the default is now to use 40 lines, not the alt screen (has its own drawbacks)
You can set “inline_height”
https://docs.atuin.sh/guide/basic-usage/#inline-window
But the inline_height seems to be a constant, rather than a percentage of the window, which is weird.
As long as you're here, do you know if the column showing the amount of time the command took can be removed? I know you can remove it from "atuin history list" with history_format, but I don't see a way to remove it from the inline window.
Thank you. In might try it again some day.
I’ve been using it for more than a year and it’s already a must for me to install whenever I spin up a new server. Great piece of software!
What are the terms and conditions regarding the data collected at api.atuin.sh
By default, the user's shell history is synced to a remote server
Unless they configure and run their own localhost server
Localhost server could be but is not the default when user enters
Instead remote server is pre-configured, asks for email, etc.Interesting design choice
I have used SQLite to store and search history instead of Postgres
Works with Bourne shell (sh), no need for Bourne-Again shell (bash) or other larger shells
What does "magical" mean in this context
I love atuin but i am not quite as fond of the UI (only because i am not used to it), so i have my own little function to use atuin with fzf instead:
Looks like it has some really nice features - https://docs.atuin.sh/configuration/key-binding/
I'm using fish + fzf atm but this looks better tbh.
Atuin has been a part of my dotfiles install.sh for the last two years. It became such an integral part of my flow that it became invisible. Prob not a good thing for them, but also a testament to how naturally it fits in.
I'm glad that there already is a tool that I was about to make. I don't usually like to change my workflow, but this seems like a very useful addition, since I can also add my history from past installations.
Is there a way to change the key binding of the search screen? I'm too attached to using the up key to recover the last command I used, and it's a little jarring to now have to click tab from the Atuin search interface. It adds a little friction each time I have to do this.
As an aside, most of my usage of history is to use the last few commands I used, and so seeing the entire history each time seems like an overkill.
There’s a whole doc page about it: https://docs.atuin.sh/configuration/key-binding/#disable-up-...
Thanks. I bound it to double up key in zsh.
> bindkey '^[[A^[[A' atuin-up-search
Works much better now!
I have been storing shell history in SQLite since 2017 [1]. I have always been a heavy shell user, with the worst memory. So having all the history stored and backed up was very useful for me. At the time when I became a full-time macOS user, I built a ShellHistory app for macOS [2], with full-text search, notebooks, and sync over iCloud (with advanced data protection [3]).
I tried to contact Atuin authors to see if I could also integrate ShellHistory with their servers, but at that time it seemed like they did not support third-party clients, and the API was not documented.
I highly recommend using tools like Atuin and ShellHistory, at this point I have 136,000 records since 2017. My shell history is the best documentation for me. If I need to do a `kubectl --raw` API call, and don't remember exactly how to write it, I just search for `kubectl raw` and get some results from the history, don't remember some advanced `git rebase`, just search the history for it.
—-
- [1] https://www.outcoldman.com/en/archive/2017/07/19/dbhist/
- [2] https://loshadki.app/shellhistory/
- [3] https://support.apple.com/en-us/108756
Edit: fixed formatting
TIL: You can also self-host atuin.
I have been using it for over 6 months self hosted, best feature is to be able to sync between all my machines. Really good to replicate my rsync across servers. And nothing leaves my private infrastructure. A breeze with docker.
The sync feature is great, though there are many oddities with search sort order, unnecessary terminal cleanups, odd timeouts, etc. In some aspects it's a big upgrade from fzf, in some aspects it's a downgrade.
The sort order is strange, I agree. I forked Atuin awhile back with the goal of adding more strategies, but it was tougher than I expected. IIRC, changing search order involves updating both the DB queries and how the application code interacts with them.
The search defaults are pretty bad, but I'm happy with "fuzzy" mode.
I'm using it, but it's still much less natural than what I had with fzf.
How does it compare to mcfly? https://github.com/cantino/mcfly
Opt-in sync with (self-hosted) server, no machine learning. Otherwise probably similar
Wow, this is incredibly useful. I was just thinking "why can't C-r just work like fzf", but this is a much better approach of course.
You can use this with Nushell! Amazing, will give it a go, though Nushell is pretty good at history search itself
I'd never sync my shell history with a third party. The self-hosting option looks interesting, but anyone comfortable with syncing their shell history with a third party is severely lacking basic privacy literacy and underestimates the sensitivity of command history.
All user data is e2e encrypted, but yes self-hosting might make you feel better about where your data lives
We wrote some more about it here: https://blog.atuin.sh/new-encryption/
I self host a atuin server.
It is a very easy thing to do.
You can use atuin without syncing it between multiple machines.
I have my shell environments divided up into different distrobox containers. Some of them sync between multiple machines. Some of them don't. Depends what the shell is for.
I recently switched to Atuin from McFly, and while McFly has been a solid performer for me for years, I love Atuin. Worth pointing out for others who care about such things as it's not made clear on this landing page, you don't actually need to register - if you don't need the sync, you can just use it without registering and it's still amazing, and if you do need the sync but don't like the idea of your history being stored on someone else's server, you can self-host the sync server too.
atuin is great been using ít for few weeks now. i like how configurable the TUI itself is. The only thing i wish it had was profiles.
I've been using it for a year or two, and it's great. it's also very easy to run your own instance of it.
Honestly been using it daily since I discovered it, great tool. Thanks.
will you add support for ksh ?
[dead]