From: Matt Joiner Date: Mon, 22 Jun 2015 09:48:50 +0000 (+1000) Subject: Document ConfigDir X-Git-Tag: v1.0.0~1146 X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;h=b5ee4f602dd9923d4a3f85957c3b41e8d6f79f6f;p=btrtrc.git Document ConfigDir --- diff --git a/client.go b/client.go index 3e63cf9b..d2c2b451 100644 --- a/client.go +++ b/client.go @@ -336,6 +336,8 @@ func (cl *Client) configDir() string { return cl.config.ConfigDir } +// The directory where the Client expects to find and store configuration +// data. Defaults to $HOME/.config/torrent. func (cl *Client) ConfigDir() string { return cl.configDir() } diff --git a/doc.go b/doc.go index e7cc1106..a15349e5 100644 --- a/doc.go +++ b/doc.go @@ -14,5 +14,14 @@ BitTorrent features implemented include: * Some IPv6 * UDP Trackers +ConfigDir + +A Client has a configurable ConfigDir that defaults to $HOME/.config/torrent. +Torrent metainfo files are cached at $CONFIGDIR/torrents/$infohash.torrent. +Infohashes in $CONFIGDIR/banned_infohashes cannot be added to the Client. A +P2P Plaintext Format blocklist is loaded from a file at the location specified +by the environment variable TORRENT_BLOCKLIST_FILE if set, otherwise from +$CONFIGDIR/blocklist. + */ package torrent