@teambun/qcup
Efficient file uploader for QCloud.
Last updated 2 years ago by m31271n_ .
MIT · Repository · Original npm · Tarball · package.json
$ cnpm install @teambun/qcup 
SYNC missed versions from official npm registry.

qcup

code style: prettier

Efficient file uploader for QCloud.

Features

  • Concurrency Support
  • Report Sheet
  • Enable / Disable / Customize HTTP Cache

Installation

$ npm install -g @teambun/qcup

Config

$ qcup gen-config

After generating ~/.qcuprc.js, read instructions in the file, set it properly.

Usage

$ qcup --help

Cache Policy

Default cache policy for development without --cache option:

File Type / File Name Expire
All 60 seconds

Cache policy for production with --cache auto option:

File Type / File Name Expire
Type - HTML 60 seconds
Type - Others 1 year

Cache policy for files in certain pattern:

File Type / File Name Expire
Name - /\.stale\./ 60 seconds

Customize cache policy with --cache option, such as:

  • --cache 0: disable cache.
  • --cache 3600: set cache time to 1 hour.

Programmatic API

async function qcup(sourceDirectory, targetDirectory, concurrency, config, interactive, cache)

Argument Type Default Value
sourceDirectory String NA
targetDirectory String NA
concurrency Number 5
config Object{ AppId, SecretId, SecretKey, Bucket, Region } NA
interactive Boolean true
cache Number NA

LICENSE

MIT

Current Tags

  • 2.0.1                                ...           latest (2 years ago)

5 Versions

  • 2.0.1                                ...           2 years ago
  • 2.0.0                                ...           2 years ago
  • 1.5.1                                ...           2 years ago
  • 1.4.2                                ...           2 years ago
  • 1.4.1                                ...           2 years ago
Maintainers (2)
Downloads
Today 0
This Week 1
This Month 2
Last Day 0
Last Week 0
Last Month 2
Dependencies (10)
Dev Dependencies (7)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |