Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

metator

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

metator

Getting information about video files from a torrent and local files.

  • 0.0.4
  • latest
  • Source
  • npm
  • Socket score

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

What is metator?

Getting information about video files from a torrent and local files.

Installation

npm i metator

Usage

Import the library in your code:

const metator = require('metator');

This is video/torrent?

  • From video
metator.isvi('./bunny.m4v').then(res => {
    console.log(res); //=> true
});
  • From torrent
metator.isto('3652DB1AFBC5D414DBCAF5920F741FF93B1ED9E5').then(res => {
    console.log(res); //=> true
});
  • From video/torrent
metator.isvt('6B!@#$%^5B').then(res => {
    console.log(res); //=> false
});

Get info from video/torrent

  • From video
metator.info('./bunny.m4v').then(res => {
    console.log(res); 
    // [ { path: './bunny.m4v',
    //     size: 3889885,
    //     file: 'bunny.m4v',
    //     sha1: '2951247a448b6123494a039623bde6b9f79603ed' } ]
});
  • From torrent
metator.info('https://archive.org/download/Colgate-Comedy-Hour-S6E1/Colgate-Comedy-Hour-S6E1_archive.torrent').then(res => {
    console.log(res);
    //[ { size: 1444438016,
    //    file: 'ColgateComedyHourS6E1.mpg',
    //    hash: '4df210f9e64d63193e41bcfbb7e3b5c540a1e874',
    //    season: 6,
    //    episode: 1 },
    //  { size: 277512087,
    //    file: 'ColgateComedyHourS6E1.ogv',
    //    hash: '4df210f9e64d63193e41bcfbb7e3b5c540a1e874',
    //    season: 6,
    //    episode: 1 },
    //  { size: 257035508,
    //    file: 'ColgateComedyHourS6E1_512kb.mp4',
    //    hash: '4df210f9e64d63193e41bcfbb7e3b5c540a1e874',
    //    season: 6,
    //    episode: 1 } ]
});
  • From video/torrent
metator.info('6B!@#$%^5B').then(res => {
    console.log(res); //=> []
});

Running tests

npm test

Keywords

FAQs

Package last updated on 10 Nov 2019

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