With :peer, which replaced the now-deprecated :slave:
opts = %{name: ~c"foo", host: ~c"localhost", connection: :standard_io}
{:ok, peer_pid, _name} = :peer.start_link(opts)
:peer.call(peer_pid, :code, :add_paths, [:code.get_path()])
:peer.call(peer_pid, IO, :puts, ["test"])
# "test"






















