New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

fetch-remote

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fetch-remote

远程拉取文件,批量替换本地对应文件

  • 1.0.4
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
decreased by-83.33%
Maintainers
1
Weekly downloads
 
Created
Source

fetch-remote

远程拉取zip文件,并且自动解压到指定目录下面

使用

1.安装

npm i --save-dev fetch-remote -d

2.引入使用

var fetch = require('fetch-remote')();
var url = 'https://github.com/JDC-FD/gulp-tasks/archive/master.zip';
var target = 'gulp_tasks.zip';
var extractDir = './';

fetch.download(url, target, function( err ){
  if( err === null ){
    fetch.extract(target, extractDir, true);    
  }
  fetch.rename( './gulp-tasks-master', './gulp', function(){
    console.log('重命名成功');
  });
});

可以调用的方法

1.download(url, dest, cb)

2.extract(source, dest, isOverWrite)

Keywords

FAQs

Package last updated on 18 Aug 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc