Skip to content

Commit 92395fc

Browse files
committed
update readme and bump version 0.8.0
1 parent 2207c2a commit 92395fc

File tree

6 files changed

+148
-114
lines changed

6 files changed

+148
-114
lines changed

MANIFEST.in

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
include LICENSE
2-
include README.md
31
include CHANGELOG.md
42
include requirements.txt
5-
include pyproject.toml
63
include Makefile
7-
include package.json
8-
include setup.py
4+
include .cbuld
5+
include tox.ini
6+
7+
recursive-include assets *
8+
recursive-include c *
99

1010
recursive-exclude * __pycache__
1111
recursive-exclude * *.pyc

README.md

Lines changed: 72 additions & 72 deletions
Original file line numberDiff line numberDiff line change
@@ -57,46 +57,11 @@ or in the _`docs`_ directory.
5757

5858
![Basic Usage](https://github.com/alexpdev/torrentfile/blob/master/assets/TorrentFileBasicUsage.gif?raw=True)
5959

60-
```bash
61-
Usage
62-
=====
63-
torrentfile [-h] [-i] [-V] [-v]
64-
create, edit, magnet,
65-
recheck, rebuild ...
66-
67-
Command line tools for creating, editing, checking and interacting with Bittorrent metainfo files
68-
69-
Options
70-
-------
71-
-h, --help show this help message and exit
72-
-i, --interactive select program options interactively
73-
-q, --quiet activate quiet mode no terminal output
74-
-V, --version show program version and exit
75-
-v, --verbose output debug information
76-
77-
Actions
78-
-------
79-
create, edit, magnet, recheck, rebuild
80-
81-
create (c, new) Generate a new torrent meta file.
82-
edit (e) Edit existing torrent meta file.
83-
84-
magnet (m) Generate magnet url from an existing Bittorrent meta file.
85-
86-
recheck (r, check) Calculate amount of torrent meta files content is found on disk.
87-
88-
info (i) Show detailed information about a torrent file.
89-
90-
rebuild (build, b) Re-assemble files obtained from a bittorrent file into the
91-
appropriate file structure for re-seeding. Read documentation
92-
for more information, or use cases.
93-
```
94-
95-
> Usage examples can be found in the project documentation on the [examples page.](https://alexpdev.github.io/torrentfile/examples)
60+
> Usage examples can be found in the project documentation on the [examples page.](https://alexpdev.github.io/torrentfile/usage)
9661
9762
## 📝 License
9863

99-
Distributed under Apache v2 software license. See `LICENSE` for more information.
64+
Apache Software License v2.0 - See [LICENSE]("https://github.com/alexpdev/torrentfile/blob/master/LICENSE")
10065

10166
## 💡 Issues & Requests & PRs
10267

@@ -108,72 +73,108 @@ If you encounter any bugs or would like to request a new feature please open a n
10873

10974
------
11075

111-
### Creating Torrents
76+
## Usage Examples
77+
78+
### Creating Bittorrent Files
11279

113-
- Basic torrent file createion
80+
Basic torrent file creation is as easy and using the `create` sub-commnand and providing
81+
the path to the contents.
11482

11583
```bash
116-
> torrentfile create /path/to/content
84+
torrentfile create /path/to/content
11785
```
11886

119-
- The `-t` `--tracker` `-a` `--announce` flags add one or more urls to list of trackers.
87+
You can add one or more trackers by using any one of `-t`, `--tracker`, `-a`, `--announce`
88+
flags and listing their URL as a space separated list.
12089

12190
```bash
122-
> torrentfile create /path/to/content --tracker http://tracker1.com
123-
124-
> torrentfile create -t http://tracker2 http://tracker3 --private /path/to/content
91+
torrentfile create /path/to/content -a http://tracker1.com http://tracker2.net
92+
```
12593

126-
> torrentfile create --tracker http://tracker /path/to/content
94+
If you intend to distribute the file on a private tracker then you should use one
95+
of `-p`, `--private` flags, which tells your Bittorrent clients to disable DHT and
96+
multitracker protocols.
12797

128-
> torrentfile create -t http://tracker1 http://tracker2 /path/to/content
98+
```bash
99+
torrentfile create /path/to/content --private
129100
```
130101

131-
- the `--private` flag indicates use by a private tracker
132-
- the `--source` flag can be used to help with cross-seeding
102+
By default __`torrentfile`__ displays a progress bar indicating how much of the content
103+
has already been processed. To turn off this display you can either use `--quiet` mode in
104+
as a global flag or you can set the `--prog` flag to 0.
133105

134106
```bash
135-
> torrentfile create --private --source EXAMPLE --tracker https://url1 https://url2
107+
torrentfile --quiet create /path/to/content
136108
```
137109

138-
The options for controlling the progress bar using `--prog` or `--progress`:
110+
```bash
111+
torrentfile create /path/to/content --prog 0
112+
```
139113

140-
- 0 : show no progress bar at all
141-
- 1 : show progress bar (default)
114+
__`torrentfile`__ automatically extracts the name of the file or directory
115+
if the content and saves the file to the current working directory with the
116+
extracted title.
117+
118+
For example running the follwing command would create `./content.torrent`.
142119

143120
```bash
144-
> torrentfile create -t http://tracker.com --progress 2 /path/to/content
145-
> torrentfile create --prog 0 /path/to/content
121+
torrentfile create /path/to/content
146122
```
147123

148-
- to specify the save location use the `-o` or `--out` flags
149-
- if the path points to directory the name of torrent is autofilled.
124+
To specify an alternative path or filename you may use the `-o`, `--out` flags
125+
followed by the relative or absolute path to your preferred output location.
150126

151127
```bash
152-
> torrentfile create -o /specific/path/name.torrent ./content
128+
torrentfile create /path/to/content -o /some/other/path/torrent.torrent
153129
```
154130

155-
- to create files using bittorrent v2 use `--meta-version 2`
156-
- likewise `--meta-version 3` creates a hybrid torrent file.
131+
If the path you specified with the `-o` flag already exists and is a directory,
132+
then torrentfile will save the output to that directory with the default extracted title.
133+
134+
For example the following command would create a Bittorrent file at `/some/other/path/content.torrent`.
157135

158136
```bash
159-
> torrentfile create --meta-version 2 /path/to/content
160-
> torrentfile create --meta-version 3 /path/to/content
137+
torrentfile create /path/to/content -o /some/other/path/
138+
```
139+
140+
Bittorrent V1 is still the most common version of torrent files and the most widely accepted,
141+
therefore by default torrentfile uses the version 1 format. However if you are using a modern
142+
Bittorrent client and tracker then you may wish to use the newest version Bittorrent V2 or
143+
a combination of the two. To do this simply use the `--meta-version` flag with the appropriate
144+
version. Options include `1`(v1 default), `2`(v2), or `3`(v1 & v2).
145+
146+
```bash
147+
torrentfile create /path/to/content --meta-version 2
148+
```
149+
```bash
150+
torrentfile create /path/to/content --meta-version 3
161151
```
162152

163153
### Check/Recheck Torrent
164154

165-
- recheck torrent file `/path/to/some.torrent` with `/path/to/content`
155+
The `recheck` subcommand allows you to scan a Bittorrent file and compare it's contents,
156+
against a file or directory containing the contents the torrent file was created from.
157+
The output provided by this process gives a detailed perspective if any files are missing
158+
or have been corrupted in any way. Supports any version of Bittorrent file.
166159

167160
```bash
168-
> torrentfile recheck /path/to/some.torrent /path/to/content
161+
torrentfile recheck /path/to/some.torrent /path/to/content
169162
```
170163

171164
### Edit Torrent
172165

173-
- edit a torrent file
166+
To edit specific fields of the torrent file, there is the `edit` subcommand. Using this
167+
subcommand you can specify the field with one of the available field flags, for example
168+
`--tracker` and specify the value you wish to change it to.
174169

175170
```bash
176-
> torrentfile edit [options] <path>
171+
torrentfile edit /path/to/content --tracker https://new.tracker.url1.com https://newtracker.url/2
172+
```
173+
174+
You can use the `-h` flag for a full list of available fields that can be edited.
175+
176+
```
177+
torrentfile edit -h
177178
```
178179

179180
### Create Magnet
@@ -182,20 +183,19 @@ To create a magnet URI for a pre-existing torrent meta file, use the sub-command
182183
`magnet` or `m` with the path to the torrent file.
183184

184185
```bash
185-
> torrentfile magnet /path/to/some.torrent
186+
torrentfile magnet /path/to/some.torrent
186187
```
187188

188189
#### Interactive Mode (expiremental)
189190

190-
Alternatively to supplying a bunch of command line arguments, `interactive mode`
191-
allows users to specify program options one at a time from a series of prompts.
192-
193-
- to activate interactive mode use `-i` or `--interactive` flag
191+
Alternatively to supplying a bunch of command line arguments, interactive mode
192+
allows users to specify program options one at a time from a series of prompts. Use the
193+
`-i` or `--interactive` flags to activate interactive mode.
194194

195195
```bash
196-
> torrentfile -i
196+
torrentfile -i
197197
```
198198

199199
### GUI
200200

201-
If you prefer a windowed gui please check out the official GUI frontend [here](https://github.com/alexpdev/TorrentFileQt)
201+
If you prefer a windowed GUI please check out the official GUI frontend [here](https://github.com/alexpdev/TorrentFileQt)

package.json

Lines changed: 0 additions & 25 deletions
This file was deleted.

pyproject.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,10 @@ build-backend = "setuptools.build_meta"
55
[project]
66
name = "torrentfile"
77
authors = [{name = "alexpdev", email = "alexpdev@pm.me"}]
8-
description = "Create Bittorent v1, v2 and hybrid meta files."
8+
description = "Terminal based command line tool for creating Bittorrent files."
99
license = {file = "LICENSE"}
1010
version = "0.8.0"
11+
url = "https://github.com/alexpdev/torrentfile"
1112
readme = "./README.md"
1213
requires-python = ">=3.6"
1314
keywords = ["Bittorrent", "torrent", "bittorrent-metafiles", "CLI"]

0 commit comments

Comments
 (0)