<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://bitpost.com/w/index.php?action=history&amp;feed=atom&amp;title=Torrent_management%3A_archive_script_%28archived_finished_torrent%29</id>
	<title>Torrent management: archive script (archived finished torrent) - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://bitpost.com/w/index.php?action=history&amp;feed=atom&amp;title=Torrent_management%3A_archive_script_%28archived_finished_torrent%29"/>
	<link rel="alternate" type="text/html" href="https://bitpost.com/w/index.php?title=Torrent_management:_archive_script_(archived_finished_torrent)&amp;action=history"/>
	<updated>2026-04-19T08:40:05Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.3</generator>
	<entry>
		<id>https://bitpost.com/w/index.php?title=Torrent_management:_archive_script_(archived_finished_torrent)&amp;diff=2224&amp;oldid=prev</id>
		<title>M: New page: &lt;pre&gt;#!/bin/bash  # We move the torrent to [archived/backup]. # We move the file(s) to [archived/symlinks/#symlink#/]. # We create a symlink to the file(s). # We wait 10 seconds to be sure...</title>
		<link rel="alternate" type="text/html" href="https://bitpost.com/w/index.php?title=Torrent_management:_archive_script_(archived_finished_torrent)&amp;diff=2224&amp;oldid=prev"/>
		<updated>2009-04-07T17:22:22Z</updated>

		<summary type="html">&lt;p&gt;New page: &amp;lt;pre&amp;gt;#!/bin/bash  # We move the torrent to [archived/backup]. # We move the file(s) to [archived/symlinks/#symlink#/]. # We create a symlink to the file(s). # We wait 10 seconds to be sure...&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
# We move the torrent to [archived/backup].&lt;br /&gt;
# We move the file(s) to [archived/symlinks/#symlink#/].&lt;br /&gt;
# We create a symlink to the file(s).&lt;br /&gt;
# We wait 10 seconds to be sure rtorrent has cleaned up.&lt;br /&gt;
# We update the torrent with a new hash and move it&lt;br /&gt;
# from [archived/backup] to [archived] so rtorrent can seed again.&lt;br /&gt;
&lt;br /&gt;
scriptdir=&amp;quot;/home/user/scripts/torrent&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# make sure directories do NOT have trailing slashes&lt;br /&gt;
torrentfile=${1%/}&lt;br /&gt;
filedir=${2%/}       # top-level file or dir in finished&lt;br /&gt;
sym=${3%/}           # new symlink location within [/archived/symlinks]&lt;br /&gt;
&lt;br /&gt;
# check to make sure everything exists&lt;br /&gt;
cd ~/download/torrents&lt;br /&gt;
if [ &amp;quot;$torrentfile&amp;quot; = &amp;quot;&amp;quot; ] || [ ! -e &amp;quot;$torrentfile&amp;quot; ]; then&lt;br /&gt;
    echo &amp;quot;I need a valid torrent file...&amp;quot;&lt;br /&gt;
    exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -e &amp;quot;finished/$filedir&amp;quot; ] &amp;amp;&amp;amp; [ ! -d &amp;quot;finished/$filedir&amp;quot; ]; then&lt;br /&gt;
    echo &amp;quot;You need to tell me where the symlink is...&amp;quot;&lt;br /&gt;
    exit 2&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
mv &amp;quot;$torrentfile&amp;quot; archived/backup/ &amp;amp;&amp;amp; mv &amp;quot;finished/$filedir&amp;quot; &amp;quot;archived/symlinks/$sym/&amp;quot; &amp;amp;&amp;amp; cd archived/symlinks/ &amp;amp;&amp;amp; ln -s &amp;quot;$sym/$filedir&amp;quot; &amp;quot;$filedir&amp;quot;&lt;br /&gt;
sleep 10&lt;br /&gt;
$scriptdir/rtorrent_fast_resume.pl 2&amp;gt;/dev/null &amp;lt;&amp;quot;../backup/$torrentfile&amp;quot; &amp;gt;&amp;quot;../$torrentfile&amp;quot; &amp;amp;&amp;amp; rm &amp;quot;../backup/$torrentfile&amp;quot;&lt;br /&gt;
&lt;br /&gt;
exit&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>M</name></author>
	</entry>
</feed>