Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.
import os import sys #path to file from the first argument (no checking) fname = sys.argv #fname = r'E:\\TV Shows\\How I Met Your Mother\\Season 6\\How.I.Met.Your.Mother.S06E18.720p.HDTV.X264-DIMENSION.mkv' # Now split the path to the directory and the bare name (better to say it # splits the last element of the path and it does not care whether it is # a file name or a subdirectory name. path, barename = os.path.split(fname) print path print barename parent = os.path.normpath(os.path.join(path, '..')) print "parent directory:", parent # Create file, delete and recreate it if it exists. This will # change the date modified status of the Show Name folder # so you can view your show list by date order. if os.path.isfile(parent + "/" + 'DateMarker.log'): os.remove(parent + "/" + 'DateMarker.log') logfile = open(parent + "/" + 'DateMarker.log', 'w') logfile.write('Episode ' + fname + ' has been created. This is a marker file, to change the date modified status of the show name.') logfile.close
Mar-02 11:44:50 INFO POSTPROCESSER :: Unable to run extra_script: [Error 193] %1 is not a valid Win32 application Mar-02 11:44:50 INFO POSTPROCESSER :: Executing command ['DateM.py', u'E:\\TV Shows\\The Mentalist\\Season 01\\the.mentalist.s01e10.720p.hdtv.x264-ctu.mkv', u'E:\\Complete\\The Mentalist S01E10 720p HDTV x264 CTU\\the.mentalist.s01e10.720p.hdtv.x264-ctu.mkv', '82459', '1', '10', '2008-12-16']
|Windows Script Host failed (Access is denied.) error||6||73|
|if "only allow certain applications" is actived in gpo, there are no batch-files running afer logon. which application should i add to get this running||2||7|
|this script icacle doesn't work on remote computers. please help||11||21|
|Active DirectoryScript to change the Pager Field||1||7|
Join the community of 500,000 technology professionals and ask your questions.
Connect with top rated Experts
11 Experts available now in Live!