]> git.lizzy.rs Git - plan9front.git/blobdiff - sys/man/1/torrent
winwatch: l allows label changes
[plan9front.git] / sys / man / 1 / torrent
index cf423d0745badc5f814fb292ee97dcfcf425b2ea..e71964e86638128a1917c0ed2ee8a6d834bb0b8f 100644 (file)
@@ -5,21 +5,30 @@ torrent \- bittorrent client
 .B ip/torrent
 [
 .B -d
-]
-[
+] [
 .B -v
-]
-[
+] [
 .B -p
-]
-[
+] [
 .B -m
 .I mtpt
-]
-[
+] [
+.B -t
+.I tracker-url
+] [
+.B -w
+.I webseed-url
+] [
 .B -s
-]
-[
+] [
+.B -c
+] [
+.B -i
+.I peer-id
+] [
+.B -A
+.I user-agent
+] [
 .I file
 ]
 .SH DESCRIPTION
@@ -29,14 +38,41 @@ that are then downloaded by clients in random order.
 As soon as a client completes a piece, it makes the piece 
 available for others to download.
 .PP
-To find find other clients (peers), a tracker-server is
+To find other clients (peers), a tracker-server is
 contacted.
 .PP
 Before files can be transmitted, a torrent-file needs
 to be created describing the pieces of the files and
 other meta-data like network addresses of the trackers.
 .PP
-.I Torrent
+This is done with the
+.B -c
+option. If provided,
+.I torrent
+reads the file given at the final
+.I file
+argument (or standard-input when omitted) and writes
+a torrent file to standard-output and exits.
+A
+.I tracker-url
+should be given with the
+.B -t
+option in that case. A list of trackers can be obtained
+on the web, see the examples below.
+.PP
+If the files in the torrent are also available from a url, a
+.I webseed-url
+can be passed with the
+.B -w
+option. If
+.I webseed-url
+ends with a slash, the filename, from the torrent, concatenated
+with the url forms the target url.
+.PP
+Without the
+.B -c
+option,
+.I torrent
 downloads the files that are described in the torrent-file
 given by the
 .I file
@@ -74,7 +110,30 @@ To monitor the download progress, the
 option can be given to cause the completed and total number of
 pieces written as a line of text to standard-output in one
 second intervals.
-.SH EXAMPLE
+.PP
+The
+.B -i
+option allows you to set the 20-byte
+.I peer-id
+that is sent to trackers and peers. If less than 20 bytes, the
+.I peer-id
+will be padded on the right with random ASCII numbers. The
+.B -A
+option allows setting the http 
+.I user-agent
+string that is used to contact the tracker. These options are
+useful to fool trackers that filter clients based on the
+.I peer-id
+or
+.I user-agent
+.
+.SH EXAMPLES
+Create new torrent file
+.EX
+ip/torrent -t http://exodus.desync.com/announce \\
+       -c 9atom.iso >9atom.torrent
+.EE
+.LP
 Download the latest iso file of the distribution 
 .EX
 cd /tmp
@@ -82,8 +141,17 @@ hget http://r-36.net/9front/9front.iso.bz2.torrent | \\
        ip/torrent -pv | \\
        aux/statusbar 'download...'
 .EE
+.LP
+Get list of public alive trackers to choose from
+.EX
+hget http://www.trackon.org/api/live
+.EE
+.LP
 .SH SOURCE
 .B /sys/src/cmd/ip/torrent.c
 .SH "SEE ALSO"
 .IR hget (1),
 .IR webfs (4)
+.SH HISTORY
+.I Torrent
+first appeared in 9front (October, 2011).