-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Switch back to global history doesn't work #1
Comments
What other history options do you have set? |
|
And what about Better yet, can you provide steps to reproduce starting with e.g. |
There's no old command in |
Works for me: $ mkdir -p .cache/zsh
$ echo test > .cache/zsh/zsh_history
$ env -i HOME=$PWD TERM=$TERM zsh -f
localhost% export HISTFILE=~/.cache/zsh/zsh_history
export HISTSIZE=50000000
export SAVEHIST=50000000
export LESSHISTFILE=-
source /home/vladimir/.config/oh-my-zsh/plugins/per-directory-history/per-directory-history.plugin.zsh Pressing Alt+L: using global history Now pressing the up arrow key correctly recalls |
Yes, it works as I simulate your steps, but somehow my current zsh configs won't work, zsh doesn't pull commands in Is there any clues that would stop it working? |
You could try to narrow it down by either bisecting (whittling down) your config to a minimal one, or by trying to debug the plugin code directly to see what it / ZSH is doing. If it helps, here's my settings: $ setopt | grep hist
extendedhistory
histexpiredupsfirst
histfindnodups
histignoredups
histignorespace
histverify
incappendhistory
sharehistory
$ set | grep HIST
HISTCHARS='!^#'
HISTCMD=820
HISTFILE=/home/vladimir/.zsh_history_dirs/home/vladimir/zsh-per-directory-history
HISTORY_SUBSTRING_SEARCH_GLOBBING_FLAGS=i
HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_FOUND='bg=magenta,fg=white,bold'
HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_NOT_FOUND='bg=red,fg=white,bold'
HISTSIZE=1000000
PER_DIRECTORY_HISTORY_BASE=/home/vladimir/.zsh_history_dirs
PER_DIRECTORY_HISTORY_FILE=zsh-per-directory-history
PER_DIRECTORY_HISTORY_TOGGLE='\el'
SAVEHIST=1000000
_per_directory_history_last_cmd='set | grep HIST' |
Test:
get default
per-directory-history.zsh
from this repo andload
it,open terminal and type something, press
alt-l
to switch back and forth between global and local history, I don't see global history there.global history I mean, commands in history file in that I put under
~/.cache/zsh/zsh_history
@CyberShadowI find that the
jimhester/per-directory-history
works.The text was updated successfully, but these errors were encountered: