1.0.7 • Published 5 years ago

cd-scp v1.0.7

Weekly downloads
3
License
ISC
Repository
github
Last release
5 years ago

cd-scp

用于webpack打包后scp到服务器的plugin(基于sftp传输,请确认服务器是否支持)

installation

npm i -D cd-scp

usage

请在webpack配置中的plugins中使用

new cdScp({
      path: resolve(__dirname, "../dist/"), //需上传路径(可以和output保持一致)
      ssh: {
        host: "xxxxx",
        port:'xxx',
        username: "xxx",
        password: "xxxx",
        path: "~"
      }
    })

通过私钥连接

new cdScp({
      path: resolve(__dirname, "../dist/"), //需上传路径(可以和output保持一致)
      ssh: {
        host: "xxx",
        port:'xxx',
        username: "xxx",
        privateKey: fs.readFileSync('私钥地址'),
        passphrase: "私钥密码",
        path: "~"}
    })
1.0.7

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago