progress-end-compress-webpack-plugin
v1.2.2
Published
webpack plugin tgz build file use ssh upload to another server
Downloads
7
Readme
progress-end-compress-webpack-plugin
Installation
npm i -D progress-end-compress-webpack-plugin
Usage
const ProgressEndCompressPlugin = require('progress-end-compress-webpack-plugin');
new ProgressEndCompressPlugin({
compressDir: {
paths: [{
sourceDir: path.resolve(__dirname, 'dist'),
targetDir: path.resolve(__dirname),
name: 'dist',
hash: [hash]
}]
},
sshConfig: {
host: '192.168.3.116',
username: 'root',
port: 22,
password: '123456',
romotePath: '/home/reedsec/web/web-api-c2b/web-view/',
replaceDirectly: false, // whether replace build folder
rename: 'dist-new' // whether rename build folder name
}
})
script: {
build: 'webpack webpack.config.js --useSsh'
}
Image Example
building
builded
server side
if set replaceDirectly = true; build folder will be replace directly.