I am either using Fedora/Debian/macOS. My setup is pretty much the same when it comes to bash.
I’m currently testing atuin on Fedora 39.
Unfortunately bash-preexec
does not work either. I thought it did, but there is still a problem somewhere with atuin. commands are only randomly added to the atuin history and I can’t figure out what the issue is. I think I might need @ellie’s help to figure out the problem.
I already got rid of the bash-git-prompt, which I thought was the reason that atuin did not record all commands (and switched to starship). But apparently that was not it either.
(The following links will point to the entire files.)
At the end of my .bashrc
I added the following lines:
[[ -f /usr/local/bin/bash-preexec.sh ]] && source /usr/local/bin/bash-preexec.sh
export STARSHIP_CONFIG=/etc/starship.toml
eval "$(starship init bash)"
eval "$(atuin init bash)"
My .bash_profile
is rather basic, and I modified the /etc/bashrc
to include a few aliases, completions, and keybindings:
[ -f /etc/bash_completion.d/fzf ] && . /etc/bash_completion.d/fzf
[ -f /usr/share/fzf/shell/key-bindings.bash ] && . /usr/share/fzf/shell/key-bindings.bash
[ -f /opt/completion/fzf_git.sh ] && . /opt/completion/fzf_git.sh
I even removed these 3 lines above for testing purposes, so that even fzf does not use any hooks, but atuin still does not add every command to the history. I just can’t figure out why that is.
For completeness I’ll link the following files as well:
/etc/bash_completion.d/fzf
/usr/share/fzf/shell/key-bindings.bash
/opt/completion/fzf_git.sh
The 3 files above won’t really help to debug the atuin problem, but @akinomyoga can see what my keybindings are. When replacing bash-preexec
with ble.sh
, and I do a Ctrl-g h
in a repo dir, I don’t get a fzf window with all my commits. Or at least I don’t see it. I think it is there, because, if I press enter
a few times it will return the first hash in the commit list. The window however will show up, when I call fzf_gh
directly. Weird, but maybe it has something to what @akinomyoga described earlier. I will have to look into that. I just need a break to get my head clear again.