How to save and load history in powershell PSReadLine module? How to save and load history in powershell PSReadLine module? powershell powershell

How to save and load history in powershell PSReadLine module?


PSReadline module save command history in file. All you need is to backup that file and restore it after reinstalling your system. You can get file name of history file by following command:

(Get-PSReadlineOption).HistorySavePath