nixpulvis / oursh

Your comrade through the perilous world of UNIX.
http://nixpulvis.com/oursh/oursh
MIT License
67 stars 6 forks source link

History is often lost on panics #13

Closed nixpulvis closed 3 years ago

nixpulvis commented 5 years ago

We shouldn't be panicking anywhere, and instead be propagating Result types, however that's another issue, to help address this issue we should append to the history file on each .add. This should play nicely with our load functionality to compress the duplicate rows automatically.

Manually "compressing" (loading and saving to remove duplicates) could also be done before exiting the shell, to leave things as clean as possible in the normal use case.

nixpulvis commented 5 years ago

FWIW, we're now dealing with result types in most places.