Skip to content

easy-tools/ftp-promise-client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ftp-promise-client

Build Status codecov NPM version

still developing, promise ftp client base on ftp

Installation

$ yarn add ftp-promise-client

How To Use

var fs = require('fs')
var path = require('path')

var FtpClientPromise = require('ftp-promise-client')

var rawPath = './app.json'
var configPath = path.join(__dirname, rawPath)
if (!fs.existsSync(configPath)) {
  throw new Error('app.json Config is not exist')
}
let appConfig = require(rawPath)

var ftpClient = FtpClientPromise.Factory(appConfig.ftp)
ftpClient.list().then(function (result) {
  console.log(result.response)
  ftpClient.close()
})

License

MIT

About

just using node-ftp but with promise

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published