|
SageTV Customizations This forums is for discussing and sharing user-created modifications for the SageTV application created by using the SageTV Studio or through the use of external plugins. Use this forum to discuss customizations for SageTV version 6 and earlier, or for the SageTV3 UI. |
|
Thread Tools | Search this Thread | Display Modes |
#201
|
||||
|
||||
Quote:
Quote:
Jere
__________________
Death to commercials!!! Latest ShowAnalyzer Beta version: 0.9.7
|
#202
|
|||
|
|||
Question: For those here who use ShowAnalzer but not DirMon, how do you startup ShowAnalzyer to process a movie after it is done recording?
If using DirMon, will is search sub-folders to process movies? If I tell DirMom to process D:\Movies folder, and I have a sub-folder D:\Movies\Classics, will it process the "Classics" movies too? |
#203
|
||||
|
||||
Quote:
If you are running Windows XP, then yes if you are using version 0.2.5. Jere
__________________
Death to commercials!!! Latest ShowAnalyzer Beta version: 0.9.7
|
#204
|
|||
|
|||
Command line options
Love this utility but i am not sure i understand the command line options completely. i have been able to use it by parsing filenames myself in external programs but i believe the commandline options would be far more usefull if some pre parsed parameters where available
what i think is happening is if i create a processor fred.exe then "fred.exe filename" is executed if i create a processor fred.exe with parameter joe peter then "fred.exe joe peter filename" is executed the problem is that often filename is not needed at the end maybe at the begining or the middle it would be nice if there where some parameters that we could use in the command line options. they may exist but i have been all through this thread and the one on your site and cant seem to find a reference to them maybe im going blind so what I thought would be nice would be if the filename is c:\sage\file.mpg %drive% = c: %path% = \sage\ %fullpath% = c:\sage\ %name% = file %ext% =mpg %filename% = c:\sage\file.mpg we could then create a command line like the following (nb i am typeing this on the fly so dont take my examples as correct there may be % or " in the wrong places -i "%filename%" -o "%fullpath%%name%.avi" or pass the individual parameters to a bat file fred.bat "%filename%" "%fullpath%" %name% then in the batch file you could program.exe "%1" "c:\outputdir\%3.avi" if errorlevel==0 echo done > "%2%3".fin ie run a program put the output in a different dir if it worked make the dontexist file have i completely missed something? -ek |
#205
|
||||
|
||||
That is an excellent idea!
Two implementation questions: 1) How should I handle paths and filenames with spaces? 2) How should I handle paths that are network drives? Should %drive% of \\media\tv\Nova.mpg be \\media or \\media\tv? Jere
__________________
Death to commercials!!! Latest ShowAnalyzer Beta version: 0.9.7
|
#206
|
||||
|
||||
most commands in MS-DOS uses quotes to deal with the path with spaces issues. Like: cd "c:\program files", I'm used to that so thats my suggestion.
__________________
Mayamaniac - SageTV 7.1.9 Server. Win7 32bit in VMWare Fusion. HDHR (FiOS Coax). HDHR Prime 3 Tuners (FiOS Cable Card). Gemstone theme. - SageTV HD300 - HDMI 1080p Samsung 75" LED. Last edited by mayamaniac; 02-09-2006 at 04:51 PM. |
#207
|
||||
|
||||
Right. But what if the user wants to quote them himself. For example:
Using D:\Videos to Archive\New\Star Trek.mpg the user wants D:\Videos to Archive\Done\Star Trek.avi We could use %fullpath%\..\Done\%name%.avi in theory. But if I wrap quotes around the parts with spaces the end result would be "D:\Videos to Archive\New"\..\Done\"Star Trek".avi and that won't work too well. If I never quote it then I'm sure there will be problems from many users about why paths with spaces don't work. Therein lies the problem. I guess I could add the option for the user to surround sequences that resolve to filenames with [[ ]]. So that [[%fullpath%\..\Done\%name%.avi]] could then be resolved as a unit and quoted if necessary. In the process I could also simplify the name so that "D:\Videos to Archive\New\..\Done\Star Trek.avi" becomes "D:\Videos to Archive\Done\Star Trek.avi". Just an idea. Jere
__________________
Death to commercials!!! Latest ShowAnalyzer Beta version: 0.9.7
|
#208
|
|||
|
|||
thanks for the quick reply
for unc i would make the drive = up until but not including the 4th \ ie \\servername\share\dir\file.exe %drive% \\servername\share %path% \dir\ %fullpath% \\servername\share\dir\ as for spaces in the name this is always so much harder than it appears if you put quotes around it we cannot concattenate them i would prefer you just left them as is then we can put the quotes as needed if you pre quote them it would be like the following batch.cmd "%fullpath%" "%name%" "%ext%" %1 = "c:\path\" %2 = "file" %3 = "ext" %1%2.%3 = "c:\path\""file"".""ext" as you can see the concatination goes crasy now some programs will accept the double double quotes but others dont if you dont quote them for us we can then do the following batch.cmd "%fullpath%%name%.%ext%" "c:\new location\%name%.new" %1 = "c:\path\file.ext" %2 = "c:\new location\file.new" we could then do copy %1 %2 by creating any concatinations we need on the command line this will work in most circumstances (except for the limit to the size of a command line) another option would be for you to create local enviroment variables that are available to the program you spawn, not sure what you have written this in and if it is feasible but as an example the following batch file dir mon would do something like set drive = xxx set path = xxx .....ect... call spawn.cmd and in our spawn.cmd file copy "%fullpath%%name%.%ext%" "c:\new path\%name%.new" you may want to call the variables something alittle more unique maybe dirmondrive or jjdrive or something that is unlikely to cause issues |
#209
|
||||
|
||||
what language are you using jere? C# has a very easy way to deal with spaces in file names without having to use quotes... probably won't help you out but thought I'd mention it...
|
#210
|
||||
|
||||
Quote:
In the end I decided that after all the %xxx% substitutions have been made, I evaluate everything between [[ and ]] for quoting. For example: Target: //media/tv/waiting for processing/CSI.mpg Command Line Options: -i [[%FULLFILESPEC%]] -o [[%DRIVE%/processed/%BASENAME%.avi]] Result: -i "//media/tv/waiting for processing/CSI.mpg" -o //media/tv/processed/CSI.avi Any comments? Jere
__________________
Death to commercials!!! Latest ShowAnalyzer Beta version: 0.9.7
|
#211
|
|||
|
|||
the quote solutions Sounds ok to me.
on a second note I love how dirmon works I get to have control over what goes on outside of sage. i currently have 2 processes 1 to run sa and one to compress files. there are a few other things i can see myself wanting to do in the future compress to ipod compress with different settings like cartoons can compress more than other programs move a file out of sage to my "to be burnt to dvd" directory get pictures etc for the shows and im sure there will be others i have 2 issues one how to kick these off currently i sa everything and use the web server to start a compress I think we need an import that just creates the tag files to kick things off. I would envisage a setup option to create the extensions we will use and then for any media file have a new option on the detailed options page create the file from a list of extentions secondly is there a limit to the number of processors and how do they interact as the number of them increase how do you set which gets fired first is it in processor number order like i may wish to commercial cut before i compress -ek |
#212
|
||||
|
||||
Quote:
Quote:
Jere
__________________
Death to commercials!!! Latest ShowAnalyzer Beta version: 0.9.7
|
#213
|
|||
|
|||
For those subscribed, and not paying attention to posts in the forums:
Announcing DirMon2: http://forums.sagetv.com/forums/showthread.php?t=16318
__________________
-Jason |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
|
|