I try to do it this way, but nothing happens.
Process.new("app_name >> app_name.log")
What is the proper syntax?
You can do this entirely within Crystal without spawning a shell using the output
option of Process.new
.
File.open("app_name.log", "a") do |file|
Process.new("app_name", output: file)
end