1

txt ファイルの内容を取得し、その内容を rtorrent のカスタム移動ディレクトリとして設定しようとしています。これがrtorrent.rcにあるものです:

system.method.insert = d.get_loaded_basename,string|simple,"execute_capture=bash,-c,\"cat /files/id.txt\",cleanbase,$d.get_loaded_file="

# insert another method to concatenate the final destination directory with the basename
system.method.insert = d.get_meta_path,simple,"cat=/files/complete/,$d.get_loaded_basename="

#watch and set custom path
schedule = watch_1,15,15,"load_start=/files/watch/*.torrent,d.set_custom1=$d.get_meta_path="

#move file to custom path and execute script
system.method.set_key = event.download.finished,move_complete,"d.set_directory=$d.set_custom1=;execute=mv,-u,$d.get_base_path=,$d.set_custom1=;execute=/files/script.sh {pass ID#}"

id.txt ファイルには 123 などの番号があります。したがって、この場合、ファイルは /files/complete/123/ に移動する必要があります。id.txt の番号はさまざまです。また、ID番号をscript.shに引数として渡したいです。どうすればこれを達成できますか?

4

0 に答える 0