Meta
TODO: Reads Elixir data structure from file (for example Keyword List) as string and converts to Elixir data
Installation
If available in Hex, the package can be installed as:
-
Add
string_to_elixirto your list of dependencies inmix.exs:
def deps do
[{:elixir_to_string, "~> 0.1.1"}]
end-
Example of usage
qwe.txtcontent
First parameter is a file name, second Module name, third function name[ my_config: [ key_value: "BA" ] ]StringToElixir("/home/zaali/qwe.txt", MyModule, func_name) MyModule.func_name == [my_config: [key_value: "BA"]]