VideoHelp Forum

Our website is made possible by displaying online advertisements to our visitors.
Please consider supporting us by disabling your ad blocker or buy PlayOn and record Netflix! :)
+ Reply to Thread
Results 1 to 8 of 8
Thread
  1. Member
    Join Date
    Apr 2008
    Location
    United States
    Search Comp PM
    Hi,

    Thanks everyone for great help in years past, I've gotten much great info from this forum.

    I've been using comskip for some years now to identify commercial breakpoints in mpg files. I use it manually from the cmd line, however, so if I have a set of mpgs, I will run it, wait for it to finish and then manually run it on the next file, until complete. Which requires me to be sitting at the computer so that I can run them one after the other.

    Is there some other tool or script that can be run which I could use to have comskip run itself for all mpg files in a given directory? I've seen something called "comskip monitor" but not sure if that will do the trick (I suppose I can DL and try it?) Note that I don't necessarily need for comskip to delete the commercials, I'm just interested in the resulting .log files which produce.

    Thanks for any help!
    Quote Quote  
  2. you just create a BAT file and run it from that folder

    Code:
    @echo off
    break>log.log
    for %%v in ("*.mpg") DO call :my_compskip "%%v"
    pause
    exit
    
    :my_compskip <video>
    echo processing %~nx1
    rem below this rem text you include whatever sequence of command lines you need to 
    rem but replace your regular name.mpg with general  "%~1"
    
    
    echo done %~nx1 >> log.log
    echo.
    goto :eof
    Quote Quote  
  3. Member
    Join Date
    Apr 2008
    Location
    United States
    Search Comp PM
    Thanks for the info!

    And just wanted to get some clarification...
    So, my comskip application is in folder C:\Users\lj01\comskip
    Let's say the folder of mpgs is in folder C:\Users\lj01\Documents\TV Shows

    Normally, i would run from cmd line and navigate to the comskip folder and then the cmd line would be comskip "C:\Users\lj01\Documents\TV Shows\show1.mpg" and so forth.

    Do i place the BAT in the "comskip" folder or the "TV Shows" folder and/or does it then matter where the comskip exe file is?

    Thanks again for your help!
    Quote Quote  
  4. Member
    Join Date
    Apr 2008
    Location
    United States
    Search Comp PM
    Got this to work -thanks for your help!

    In case anyone else wondering, yes, you do copy the comskip folder into the folder you are running from - works brilliantly!

    Thank you so much, _Al_!
    Quote Quote  
  5. Member
    Join Date
    Nov 2017
    Location
    North America
    Search PM
    Originally Posted by _Al_ View Post
    you just create a BAT file and run it from that folder

    Code:
    @echo off
    break>log.log
    for %%v in ("*.mpg") DO call :my_compskip "%%v"
    pause
    exit
    
    :my_compskip <video>
    echo processing %~nx1
    rem below this rem text you include whatever sequence of command lines you need to 
    rem but replace your regular name.mpg with general  "%~1"
    
    
    echo done %~nx1 >> log.log
    echo.
    goto :eof
    Sorry for reopening an old thread, but this is exactly what I'm looking for. I would like to ask though if there is a way to make it recursive into subfolders though...
    Quote Quote  
  6. try to add /R in that FOR command, that should include subdirectories:
    Code:
    for /R %%v in ("*.mpg") DO call :my_compskip "%%v"
    if not, then include that root folder path as well:
    Code:
    for /R "C:\main_folder\" %%v in ("*.mpg") DO call :my_compskip "%%v"
    Quote Quote  
  7. Member
    Join Date
    Nov 2017
    Location
    North America
    Search PM
    That did it. Thank you for your super speedy response!
    Quote Quote  
  8. ok, in that case you can print whole path into that log as well, so it is not a mess:
    Code:
    echo done %~dpnx1
    echo done %~dpnx1 >> log.log
    it is printed into cmd prompt and again into a file that could be checked with notepad, what has been processed so far
    Quote Quote  



Similar Threads