Should .iex.exs be committed or ignored?

Is .iex.exs something I should commit to my codebase?

I feel like it is really developer-dependant but I also see it very useful to share.

Not committed, in my opinion. As you say, .iex.exs is a very personal thing per developer.

3 Likes

Yeah, I would add it to .gitignore

I would commit it if uts useful to other devs. What would be the personal preferences you put in?

You can commit it, and if any dev wants a custom one, then your global .iex.exs could end with if File.exists?(".iex.local.exs"), do: Code.eval_file(".iex.local.exs") so any dev can also have their own things. (.iex.local.exs is git ignored)

In ours we have some default aliases / imports and a few iex-only helper functions.

2 Likes

Aliases for instance strikes me as a very personal thing.