my-wget

1.1.0 • Public • Published

my-wget

NPM version Build Status Dependency Status Coverage percentage

Installation

npm install --save my-wget

Usage

download(url, [options], cb);

option:

  • dest (string): destination of the downloaded file.
  • ext (boolean): extract file
  • strip (integer): how many path segments to strip from the root when extracting
var download = require('my-wget');
 
var url = 'path to file';
download(url, {dest: 'path to destination', ext: false}, function (err, res) {
  // do something
})

Or just omit the option, so it will download it into the current directory

download(url, function (err, res) {
  // do something
})

Created with

Yeoman and Generator-simple-package

License

MIT © NghiaTTran

Readme

Keywords

none

Package Sidebar

Install

npm i my-wget

Weekly Downloads

0

Version

1.1.0

License

MIT

Last publish

Collaborators

  • nghiattran