1.0.0 • Published 1 year ago

archiver-rar v1.0.0

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

archiver-rar

ArchiverJS RAR Support

Rar for Linux or WinRar for Windows should be installed. Visit the ArchiverJS for examples.

Install

npm install archiver archiver-rar --save

Quick Start

// Auto register
const archiver = require('archiver-rar')(require('archiver'));
// Manual register
const archiver = require('archiver');
const { module } = require('archiver-rar');

archiver.registerFormat('rar', module);

Usage

// Options
const options = {
    rate: 3, // Compress rate (0-5)
    baseDir: 'Backup', // Base directory in rar file
    password: 'dummy', // Password for the file
    comment: 'Rar file comment', // Comment of the file <string|Buffer|file.txt>
    extra: [], // Extra rar Switches
}

const archive = archiver('rar', options);

All Rar Switches list.

1.0.0

1 year ago