forked from pyroscope/rtorrent-ps
-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Modify directory.watch.added and add directory.watch.removed command #87
Labels
Milestone
Comments
chros73
pushed a commit
that referenced
this issue
Jun 11, 2017
chros73
pushed a commit
that referenced
this issue
Jul 11, 2017
zmike808
pushed a commit
to zmike808/rtorrent-ps-ch
that referenced
this issue
May 18, 2019
This fixes compilation on Arch Linux ARM systems
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
One of the advantages of using "inotify" to load and remove downloads by torrent meta files is the reduced file system IO (apart from it's instant).
A. Modify
directory.watch.added
Allow it to accept multiple commands (as
load.*
commands).There are multiple ways to achieve this but since there's no "shortcut" (the directory (that is watched) for inotify has to be separated), the final command (that is called on an "add" event) is reconstructed as a line of config.
load.*
commands),
parameter separator) then it needs to be included inside quotes ("
)B. Add
directory.watch.removed
Similarly to loading event, add ability to handle removing events of meta files as
*_untied
commands:*_untied
commands can't deal with a download individually: they go through and check all the downloads (they can generate lot of IO, especially if they are used withschedule
command)directory.watch.removed
handles this individuallySince it doesn't need any additional commands, it accepts multiple directories as parameters.
d.stop
,d.close
,d.erase
directory.watch.removed = d.erase, (cat,(cfg.dir.meta_compl),various/), (cat,(cfg.dir.meta_compl),unsafe/)
C. Rename
*tied
commandsRename untied commands and add redirects for the new names to preserve compatibility:
start_tied
->tied.start
stop_untied
->untied.stop
close_untied
->untied.close
remove_untied
->untied.remove
D. Limitations
directory.watch.added
ordirectory.watch.removed
E.
directory.watch.*
commands in actionLet's assume the following:
The text was updated successfully, but these errors were encountered: