Run programs as functions in Elixir
An Elixir module inspired by Python's sh package.
Shallows you to call any program as if it were a function.
To use Sh with your projects, simply edit your mix.exs file and add it as a dependency:
defp deps do [{:sh, "~> 1.1.2"}] end
iex> Sh.echo "Hello World!" "Hello World!\n"
Shcommands accept as the last argument a list of options.
Sh.curl "http://example.com/", o: "page.html", silent: true ""
The equivalent call without using this feature would be:
Sh.curl "-o", "page.html", "--silent", "http://example.com/"
Underscores in a program name or keyword options are converted to dashes.