A Simple FTP Client based on :inets
If available in Hex, the package can be installed
by adding eftp
to your list of dependencies in mix.exs
:
def deps do
[{:eftp, github: "audian/eftp"}]
end
To authenticate and download the file example.csv
Eftp.connect("ftp.example.net", "21")
|> Eftp.authenticate("foo", "bar")
|> Eftp.fetch("example.csv", "/tmp")
To authenticate and download a list of files example.csv
, users.csv
Eftp.connect("ftp.example.net", "21")
|> Eftp.authenticate("foo", "bar")
|> Eftp.fetch(["example.csv", "users.csv"], "/tmp")