Script I made to clean my Downloads folder, for now includes a Transmission module, that is capable of nothing more than listing and removing torrents.
JavaScript Shell
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
transmission
.gitignore
LICENSE.md
README.md
clean-downloads.js
movefiles.sh

README.md

clean-downloads

The script finds all files in your Download folder > 500 M and moves them to another folder. Since these more than often are active transfers in Transmission (http://www.transmissionbt.com) I've made the script connect to Transmission's API to remove them, as long as they're not unfinished or partially transferred (i.e. have unchecked files). In the latter case the files are kept in the Downloads folder.

Usage

clean-downloads.js - moves files to ~/totransfer

movefiles.sh transfers the files to another volume, in my case mounts a second harddrive.

I have these cron scheduled.

Authors

  • Emil Stenqvist @emilisto

TODO

  • Clean up code
  • Make more general - specify paths as command line parameters
  • Move the Transmission library to a separate project and develop it