webpack-ftp-upload-plugin
A webpack ftp upload plugin.
Last updated 9 years ago by tgxh .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ npm install webpack-ftp-upload-plugin 
SYNC missed versions from official npm registry.

Webpack-ftp-upload-plugin

A webpack ftp upload plugin, support upload file or folder to ftp server.

Installation

npm i -D webpack-ftp-upload-plugin

Usage

add following code to your webpack config file.

var WebpackFtpUpload = require('webpack-ftp-upload-plugin')

new WebpackFtpUpload({
    host: 'host',
    port: 'post', // default: 22
    username: 'user',
    password: 'password',
    local: 'local path', // eg. path.join(__dirname, 'dist')
    path: 'remote path', // eg. /var/www/ftp/
})            

Simple example

var path = require('path')
var WebpackFtpUpload = require('webpack-ftp-upload-plugin')

module.exports = {
    entry: './index.js',
    output: {
        path: path.join(__dirname, 'dist'),
        filename: 'index_bundle.js'
    },
    plugins: [
        new WebpackFtpUpload({
            host: '127.0.0.1',
            port: '22',
            username: 'root',
            password: '123456',
            local: path.join(__dirname, 'dist'),
            path: '/var/www/ftp/',
        })
    ]
}

License

This project is licensed under MIT.

Current Tags

  • 1.0.3                                ...           latest (9 years ago)

4 Versions

  • 1.0.3                                ...           9 years ago
  • 1.0.2                                ...           9 years ago
  • 1.0.1                                ...           9 years ago
  • 1.0.0                                ...           9 years ago
Maintainers (1)
Downloads
Total 7
Today 0
This Week 3
This Month 6
Last Day 0
Last Week 3
Last Month 0
Dependencies (2)
Dev Dependencies (0)
None
Dependents (0)
None

© 2010 - cnpmjs.org x YWFE | Home | YWFE