Temporarily disable CLI history for application?

Hello all,

I have been in the process of creating a Gemini client (basically a ridiculously bare-bones web browser) that, at least for now, starts in the IEX REPL and, naturally, shares its history.

I was wondering if there is an easy way to temporarily turn off history altogether for the session, so that you don’t get a CLI history at all and have to rely on the application’s way of managing history rather than Elixir’s. When the application is closed, going back to whatever history configuration the host machine has would be desirable in case the person running it programs in Elixir.

Other approaches to getting this behavior are also certainly welcome. I’m trying to keep this as simple as possible though, and didn’t want to use something like a TUI framework.

Thanks in advance!

1 Like

Just set stdlib configuration to requested values.

ERL_FLAGS="-stdlib shell_saved_results 0 -stdlib shell_history_length 0" <run your app>

Ah, very nice. I can just put together a shell script that sets that and runs it.


1 Like