mirror of
https://github.com/clinton-hall/nzbToMedia.git
synced 2025-08-14 02:26:53 -07:00
use linktastic
thanks berkona
This commit is contained in:
parent
2f65f0d7fc
commit
a09b5e0fda
1 changed files with 2 additions and 7 deletions
|
@ -4,7 +4,7 @@ import autoProcessMovie
|
|||
import autoProcessTV
|
||||
import sys, os, ConfigParser, shutil
|
||||
import logging, logging.config
|
||||
from subprocess import call
|
||||
import linktastic
|
||||
|
||||
from nzbToMediaEnv import *
|
||||
|
||||
|
@ -222,12 +222,7 @@ elif useLink == 1 and packed == 0 and video == 1: ## hardlink
|
|||
source = os.path.join(dirpath, file)
|
||||
target = os.path.join(destination, file)
|
||||
|
||||
if os.name == 'nt':
|
||||
subprocess.call(['cmd', '/C', 'mklink', '/H', source, target], stdout=subprocess.PIPE)
|
||||
elif os.name == 'posix':
|
||||
os.link(source, target)
|
||||
else:
|
||||
Logger.info("Hardlink failed, cannot determine OS.")
|
||||
linktastic.link(source, target)
|
||||
|
||||
elif packed == 1: ## unpack
|
||||
## Using Windows?
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue