node-libtorrent-mt
node-libtorrent provides native bindings to libtorrent rastebar as a Node.js addon.
this is a fork of https://github.com/fanatid/node-libtorrent
Getting started
Execute in command line:
$ npm install node-libtorrent-mt
or copy repository and build bindings manually
$ git clone git://github.com/martintrojer/node-libtorrent.git
$ cd node-libtorrent
$ npm install -g node-gyp
$ node-gyp configure
$ node-gyp build
Examples
Simple client
lt = require "../build/Release/libtorrent" s = slisten_on68816889ti = "./test.torrent"th = sadd_torrent ti: ti save_path: "./test_torrent"= -> st = thstatus consolelog " complete \(down: kb/s | up: kB/s | \peers: )" setTimeout main2500main
Create torrent
lt = require "../build/Release/libtorrent" fs = ltadd_files fs"./src"ct = fsltset_piece_hashes ct"."t = ltbencode ctgenerateconsolelog t