defmodule Mix.Tasks.GetInput do def run(args) do [year, day] = args write_file = &File.write("./input/#{year}_#{day}.txt", &1) AoC.fetch_input!(year, day) |> then(fn i -> IO.puts(i) i end) |> write_file.() end end