Emin Arslan 1503ca4fab Initial
2025-02-16 19:14:35 +03:00

26 lines
453 B
Elixir

defmodule Broadcast do
@moduledoc """
A simple broadcast server
"""
use Application
def console_loop() do
case IO.read(:stdio, :line) do
"mem\n" ->
IO.inspect :erlang.memory()
_ -> IO.puts "unknown command entered"
end
console_loop()
end
def main(_args \\ []) do
IO.puts "started"
{:ok, _} = Broadcast.Server.start(8080)
console_loop()
end
def start(_type, _args) do
main()
end
end