I want to execute a code every minute and I tried an attempt using the following code:
#your_app/mix.exs
defp deps do
[{:quantum, ">= 1.9.1"},
#rest code
end
#your_app/mix.exs
def application do
[mod: {AppName, []},
applications: [:quantum,
#rest code
]]
end
#your_app/config/dev.exs
config :quantum, :your_app, cron: [
# Every minute
"* * * * *": fn -> IO.puts("Hello QUANTUM!") end
]
This is the one of the answers to this question How to run some code every few hours in Phoenix framework?
However, when I execute iex -S mix it doesn't show any message, neither an error message.
Do you know what the problem would be?