Skip to content

Instantly share code, notes, and snippets.

@arielkirkwood
Created April 28, 2013 21:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save arielkirkwood/5478422 to your computer and use it in GitHub Desktop.
Save arielkirkwood/5478422 to your computer and use it in GitHub Desktop.
Shell script for Transmission that copies downloaded files to a separate directory (for processing, or syncing via Dropbox or BitTorrent Sync)
#! /bin/bash
# by @neonelectro on github (Ariel Kirkwood)
DEST_DIR="" # put a file path for the copied files in the quotes
NOW=$(date +%Y-%m-%d\ %H:%M:%S)
cd # put the file path to your downloads folder after cd (and the space)
echo "$NOW Copying $TR_TORRENT_NAME to $DEST_DIR" >> $DEST_DIR/copying.log
echo "====================================================" >> $DEST_DIR/copying.log
cp -Rv "$TR_TORRENT_NAME" "$DEST_DIR" >> $DEST_DIR/copying.log
echo >> $DEST_DIR/copying.log #line break between logs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment