jimhester / per-directory-history

Per directory history for zsh, as well as global history, and the ability to toggle between them with ^G.
zlib License
260 stars 36 forks source link

Cannot deal with a directory name including whitespaces when sh_word_split is on #52

Open aoyama-val opened 4 months ago

aoyama-val commented 4 months ago
$ setopt sh_word_split
$ mkdir 'foo bar'
$ cd 'foo bar'
$ ls
_per-directory-history-addhistory:11: failed to write history file /Users/xxx/.local/share/directory_history/Users/me/tmp/foo: is a directory
_per-directory-history-change-directory:9: failed to write history file /Users/xxx/.local/share/directory_history/Users/me/tmp/foo: is a directory

I think we need to quote variables properly.