-- Simple wget.
local args = {...}
local dl = http.get(args[1])
print(dl)
if not dl then
  print("HTTP API ERROR")
  return
end
local fl = shell.resolve(args[2])
if fs.exists(fl) then
  print("File already exists!")
  return
end
local file = fs.open(fl,"w")
file.write(dl.readAll())
dl.close() file.close()
