Rendered at 07:31:05 GMT+0000 (Coordinated Universal Time) with Cloudflare Workers.
NightMKoder 24 hours ago [-]
FWIW I use atuin (https://atuin.sh/) and am reasonably happy with it, especially the infinite capacity & snapiness. Ignoring the sync features, I believe it's also sqlite backed when running in local-only mode.
Valodim 22 hours ago [-]
The readme starts by saying how the author used to use atuin, and why they wrote stinkpot as a less featureful alternative.
tstenner 23 hours ago [-]
AFAIK it is always backed by a sqlite DB. That way the sync just populates the DB and the completion process doesn't care (or wait for) the central source.
INTPenis 15 hours ago [-]
So can it run without AI? They promote their own AI on the website and that is really the last thing I want in my Shell
PROMPT_COMMAND has the following flaw: a command gets recorded as soon as it has finished. So command which never finish (e.g. because they run for a long time, and the user closes the terminal window, or reboots the system) never get recorded. Another flaw: the users starts a long-running command in terminal window 1, and immediately they want to start a variant of it in terminal window 2, but it's not available in the history.
superb_dev 14 hours ago [-]
What would be a better entry point? I honestly thought there would some hook for saving history specifically
unixhero 3 hours ago [-]
You should track all processes spawned by bash
inigyou 12 hours ago [-]
Modify bash?
lucideer 18 hours ago [-]
<unrelated side note for the author>
I would never normally mention this, but I'm reading this repo on mobile & it seems Forgejo doesn't wrap .txt files on mobile. Any reason not to use .md for a new project in 2026?
exiguus 12 hours ago [-]
I looked it up, because for me it looked kind of cool. It's tangled not Forgejo when i got it right.
Ah! I misunderstood - they were talking about forgejo & I skimmed too quickly & read it as Tangled being a forgejo host (akin to e.g. Codeberg). Turns out it's their own stack - very cool, I'm more interested now.
It is written entirely in shell script, with the only dependency being sqlite itself.
gertrunde 20 hours ago [-]
For me personally, while I like the history element, if I'm gathering/storing/searching everything, I'd love to also see the command output with the entered command, giving much better context.
Currently I tend to log all my ssh sessions out to text files and grep through the whole lot to find what I want, so a better version of that would be lovely, especially if it could automatically redact secrets or similar, as I'm aware thats a downside of the current setup.
podocarp 1 days ago [-]
A little curious but too lazy to find out, what's the difference between this and atuin vs fzf?
Also I do like the premise, recently stopped using atuin due to all the extra bells and whistles and just went back to fzf.
apodik 24 hours ago [-]
seems to only have session agnostic history and a TUI for searching it, because the author didn't want all the features atuin offers. only 400 LOC too, pretty neat
danofsteel32 20 hours ago [-]
I recently “fixed” my bash history since the default experience when using multiple terminals sucks.
Just enable perpetual bash history and install fzf.
That will get you CTRL-R (and a lot of other niceties) out of the box.
mkesper 19 hours ago [-]
How do these compare to the fish builtin history search with dir awareness and completion menu? I found it quite an improvement to bash history handling but fish isn't POSIX compatible so sometimes you need to switch back and forth.
jiehong 17 hours ago [-]
As a user of atuin, it also keep track of the status code of a previous command, as well as its execution time.
It’s quite handy.
apodik 23 hours ago [-]
is there a particular reason why i'd want sqlite-backed shell history? i mean sure it works but why not a text file? (which i'd assume is somewhat faster because you can just append)
i guess you could say it's because you may want dates for each command but for that you can just use a CSV or TSV file no?
does it have to do with the searching?
vladvasiliu 23 hours ago [-]
In my case, I use Atuin. It has a concept of "context" so you can easily search the history for commands related to your current directory / project / etc. See [0] for some examples.
Now, I admit I don't use these that often, but they can be useful.
It also does stats and whatnot based on the history. I've never looked at those.
I have a regular Bash shell history with about 750 000 entries on an SSD on a modern laptop, and would take about 1 second for Bash to load 1 million entries. The startup delay and the memory usage is noticeable.
Storing the shell command history in a database instead of the memory of each interactive Bash shell, it would make Bash start up faster, and also use less memory.
fpoling 23 hours ago [-]
SQLite gives indexes that makes searching and locating previous entries much faster. This is relevant when the history is over 100K entries and one wants to avoid duplicates in history files.
OskarS 23 hours ago [-]
I think you're underestimating the speed of modern computers and hard-drives, fzf can search through 100k entries easily without any delay. Try it with `cat /usr/share/dict/words | fzf`, it's extremely responsive (my dictionary is about 235k lines). If you want hard numbers, try piping your shell history through `time grep` and see how long finding an entry takes.
Even if you're on spinning rust, your shell history is probably in cache. You don't really need FST index for this usecase, IMHO.
Kubuxu 21 hours ago [-]
I use SQLite history to have context aware line suggestion in my shell. So the command that gets ghost displayed (and can be expanded with right arrow) depends on the current working directory, its parents and recency.
This is fast enough using SQLite to just dump all commands into it and query on each typed letter.
The DB is at this point 10years old. I use it to evaluate my work habits and patterns.
More recently I have started transitioning to a different shell and I used it to move only the functions and aliases I still use, instead of the full collection.
fpoling 16 hours ago [-]
With SQLite one automatically gets reliable persistent storage. Try to emulate that with a text file with history that eliminates duplicates. It is surprisingly hard to archive.
chaz6 20 hours ago [-]
Perfect! I wanted this without all the extras of atuin that I never use.
I'm only interested in how it treats multiline commands in bash. It's the only thing that the default history doesn't do consistently (unless you make it replace \n with ;, which is just unuable). Otherwise, fzf + history works just fine.
firasd 21 hours ago [-]
Would be interesting to have a non-interactive mode so you can ask your AI to look for a command too.. but I guess if it's sqlite underneath then it's already de facto possible (and the the cltr+r may be usable from harnesses too not sure)
shim__ 23 hours ago [-]
Does it support just synching the db via nextcloud or similar? I'd prefer to stick to the Unix philosophy of one tool for one job instead of native cloud integration
icy 21 hours ago [-]
I mean, it's an sqlite file on disk. You can sync it however you like. https://litestream.io is a fun choice.
shim__ 16 hours ago [-]
Of course but my question was more in the direction of if the data is suitable to be transferred to another host without becoming useless. The native cloud integration could be attaching an origin field to each history field whereas the db itself might only be intended for local only use.
blepblep 23 hours ago [-]
For me the killer feature of atuin is that it allows searching the history of commands executed from the current working directory. Typically I have 10,000 plus commands in history but only a few in the current directory and I tend to run the same complex commands from the same directory.
hakcermani 23 hours ago [-]
created this gnome-extension to launch a gnome terminal with separate history files. bash script gt.sh [projname] launches a gnome-terminal with a history file in ~/.histories/projname
PROMPT_COMMAND has the following flaw: a command gets recorded as soon as it has finished. So command which never finish (e.g. because they run for a long time, and the user closes the terminal window, or reboots the system) never get recorded. Another flaw: the users starts a long-running command in terminal window 1, and immediately they want to start a variant of it in terminal window 2, but it's not available in the history.
I would never normally mention this, but I'm reading this repo on mobile & it seems Forgejo doesn't wrap .txt files on mobile. Any reason not to use .md for a new project in 2026?
[1] https://tangled.org/
It is written entirely in shell script, with the only dependency being sqlite itself.
Currently I tend to log all my ssh sessions out to text files and grep through the whole lot to find what I want, so a better version of that would be lovely, especially if it could automatically redact secrets or similar, as I'm aware thats a downside of the current setup.
Also I do like the premise, recently stopped using atuin due to all the extra bells and whistles and just went back to fzf.
https://dandavis.dev/the-bash-history-i-always-wanted.html
I also use fzf to search my history I believe you just need so source the right keybindings file to make ctrl+r use fzf.
It’s quite handy.
i guess you could say it's because you may want dates for each command but for that you can just use a CSV or TSV file no?
does it have to do with the searching?
Now, I admit I don't use these that often, but they can be useful.
It also does stats and whatnot based on the history. I've never looked at those.
[0] https://docs.atuin.sh/latest/guide/advanced-usage/
Storing the shell command history in a database instead of the memory of each interactive Bash shell, it would make Bash start up faster, and also use less memory.
Even if you're on spinning rust, your shell history is probably in cache. You don't really need FST index for this usecase, IMHO.
The DB is at this point 10years old. I use it to evaluate my work habits and patterns. More recently I have started transitioning to a different shell and I used it to move only the functions and aliases I still use, instead of the full collection.
(https://github.com/appsmatics/gtsh-hist)