batch script

Tagged: ,

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #2089
    Lukasz Priba
    Participant

    Hi,

    I’m running jMRUI AMARES analysis on some of my data in batch mode. I’m trying to script the analysis so it repeats the process on other datasets. I’m running into a small problem where the cmd remains open after each analysis – any idea how I can terminate cmd after AMARES is completed? I expected “exit” or “exit /b” to do the trick but (sadly) it didn’t

    many thanks

    #2167
    Mariano Uberti
    Participant

    Hi:

    If you are running your script on Windows, create a batch script that 1) Calls Amares batch script and then 2) kills the command window. The script would look something like:

    CALL MyAmaresBatchScript.bat &
    taskkill /IM cmd.exe

    However, you should be careful in making sure that the AMARES “results” file gets completely written into disk before you “kill” the command line. So I suggest to add some pause before you kill the command line (e.g. 3s pause):

    CALL MyAmaresBatchScript.bat &
    timeout 3
    taskkill /IM cmd.exe

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.