dtorrent_parser 1.0.9 copy "dtorrent_parser: ^1.0.9" to clipboard
dtorrent_parser: ^1.0.9 copied to clipboard

A Dart library for parsing .torrent file to Torrent model/saving Torrent model to .torrent file.

A Dart library for parsing .torrent file to Torrent model/saving Torrent model to .torrent file.

codecov

Support #

Usage #

A simple usage example:

Parse .torrent file #

import 'package:dtorrent_parser/dtorrent_parser.dart';

main() {
  ....

  var model = Torrent.parse('some.torrent');

  ....
}

Use Torrent class' static method parse to get a torrent model. The important informations of .torrent file can be found in the torrent model , such as announces list , infoHash ,etc..

Testing #

Run tests:

dart test

Run tests with coverage:

dart test --coverage=coverage
dart run coverage:format_coverage --lcov --in=coverage --out=coverage/lcov.info --packages=.dart_tool/package_config.json --report-on=lib

Or use the provided script:

dart tool/coverage.dart

The coverage report will be generated at coverage/lcov.info and can be viewed with tools like genhtml or uploaded to services like Codecov.

Coverage is automatically uploaded to Codecov on every push and pull request via GitHub Actions.

Features and bugs #

Please file feature requests and bugs at the issue tracker.

3
likes
160
points
239
downloads

Publisher

unverified uploader

Weekly Downloads

A Dart library for parsing .torrent file to Torrent model/saving Torrent model to .torrent file.

Repository (GitHub)
View/report issues

Documentation

API reference

License

BSD-3-Clause (license)

Dependencies

b_encode_decode, crypto

More

Packages that depend on dtorrent_parser