lib-ftp
Table of Contents generated with DocToc
Example usage
import { toStr } from '/lib/enonic/util';
import Ftp from '/lib/enonic/ftp';
const ftp = new Ftp({
host: 'speedtest.tele2.net',
username: 'anonymous',
password: 'anonymous@example.com'
}).connect().login();
const names = ftp.getNames(); DEBUG && log.debug(`names:${toStr(names)}`);
const fileContent = ftp.retrieveFile({ remote: '/1KB.zip' });
log.debug(`fileContent:${toStr(fileContent)}`);
ftp.logout().disconnect();
Documentation
See jsdoc generated documentation
Compatibility
Version | XP version |
---|---|
1.0.0 | 6.11.1 |
Changelog
1.0.0
- Made Ftp class.
- Added connect, login, getNames, retrieveFile, logout and disconnect methods.
TODO
- Add more methods