mirror of
https://github.com/rakshasa/rtorrent.git
synced 2026-10-05 21:59:21 +00:00
Create instance directories as part of the config
+9
-11
@@ -16,22 +16,16 @@ use-cases in the appropriate sections of the wiki, like the
|
||||
|
||||
## Using the Template
|
||||
|
||||
To create the directory tree this configuration expects, use these commands:
|
||||
|
||||
```sh
|
||||
basedir="$HOME/rtorrent"
|
||||
mkdir -p "$basedir"/{.session,download,log,watch/load,watch/start}
|
||||
```
|
||||
|
||||
The `basedir` value has to be the same you set in `cfg.basedir` below.
|
||||
|
||||
Use this command to get a copy of the template to your disk:
|
||||
|
||||
```sh
|
||||
curl -Ls https://raw.githubusercontent.com/wiki/rakshasa/rtorrent/CONFIG-Template.md \
|
||||
| grep -A9999 '^######' | grep -B9999 '^### END' >~/.rtorrent.rc
|
||||
curl -Ls "https://raw.githubusercontent.com/wiki/rakshasa/rtorrent/CONFIG-Template.md" \
|
||||
| grep -A9999 '^######' | grep -B9999 '^### END' \
|
||||
| sed -re "s:/home/USERNAME:$HOME:" >~/.rtorrent.rc
|
||||
```
|
||||
|
||||
Then (re-)start rTorrent.
|
||||
|
||||
## The Template
|
||||
|
||||
:construction: | This is NOT complete yet!
|
||||
@@ -52,6 +46,10 @@ method.insert = cfg.watch, private|const|string, (cat,(cfg.basedir),"watch/
|
||||
method.insert = cfg.logs, private|const|string, (cat,(cfg.basedir),"log/")
|
||||
method.insert = cfg.logfile, private|const|string, (cat,(cfg.logs),"rtorrent-",(system.time),".log")
|
||||
|
||||
# Create instance directories
|
||||
execute.throw = bash, -c, (cat,\
|
||||
"mkdir -p \"", (cfg.basedir), "\"{.session,download,log,watch/load,watch/start}")
|
||||
|
||||
# Listening port for incoming peer traffic (fixed; you can also randomize it)
|
||||
network.port_range.set = 50000-50000
|
||||
network.port_random.set = no
|
||||
|
||||
Reference in New Issue
Block a user