Saving current directory to bash history

后端 未结 9 1935
时光取名叫无心
时光取名叫无心 2020-11-28 19:29

I\'d like to save the current directory where the each command was issued alongside the command in the history. In order not to mess things up, I was thinking about adding

9条回答
  •  迷失自我
    2020-11-28 19:57

    For those who want this in zsh I've modified Jeet Sukumaran's implementation and percol to allow interactive keyword searching and extraction of either the command or path it was executed in. It's also possible to filter out duplicate commands and hide fields (date, command, path)

提交回复
热议问题