• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

popomore/gulp-scp2: Copy file to remote server, using scp2 that is a pure javasc ...

原作者: [db:作者] 来自: 网络 收藏 邀请

开源软件名称(OpenSource Name):

popomore/gulp-scp2

开源软件地址(OpenSource Url):

https://github.com/popomore/gulp-scp2

开源编程语言(OpenSource Language):

JavaScript 100.0%

开源软件介绍(OpenSource Introduction):

gulp-scp2 Build Status Coverage Status

Copy file to remote server, using scp2 that is a pure javascript implement.


Install

$ npm install gulp-scp2 -g

Usage

var gulp = require('gulp');
var scp = require('gulp-scp2');

gulp.task('default', function() {
  return gulp.src('**/*.js')
  .pipe(scp({
    host: 'localhost',
    username: 'username',
    password: 'password',
    dest: '/home/username/'
  }))
  .on('error', function(err) {
    console.log(err);
  });
});

More see example

Options

options.host

Type: String Default value: localhost

A string value that is the host of the server.

options.port

Type: Number Default value: 22

The ssh port of the server.

options.username

Type: String Default value: admin

The username of the server.

options.password

Type: String

The password of the user on the remote server.

options.dest

Type: String Default value: /home/username

Remote server directory

options.watch

Type: Function

You can get the client instance, and watch events.

More Options

  • host
  • port
  • hostHash
  • hostVerifier
  • username
  • password
  • agent
  • privateKey
  • passphrase
  • publicKey

Read more: https://github.com/mscdex/ssh2#connection-methods

LISENCE

Copyright (c) 2015 popomore. Licensed under the MIT license.




鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap