Kernel.inspect:
iex(12)> list = [
...(12)> {:phoenix, "~> 1.6.6"},
...(12)> {:sourceror, "~> 0.11.1"},
...(12)> {:mishka_installer, git: "https://github.com/mishka-group/mishka_installer.git"}
...(12)> ]
[
phoenix: "~> 1.6.6",
sourceror: "~> 0.11.1",
mishka_installer: [
git: "https://github.com/mishka-group/mishka_installer.git"
]
]
iex(13)> Kernel.inspect list
"[phoenix: \"~> 1.6.6\", sourceror: \"~> 0.11.1\", mishka_installer: [git: \"https://github.com/mishka-group/mishka_installer.git\"]]"
iex(14)>
Depending on what you plan to do with the string, you might also consider erlang’s term_to_binary/1,2.






















