• Refresh Baidu Zhidao Evaluate Num 2.0


    main.bat

     1 @echo off
     2 color 0a
     3 title Refresh Baidu Zhidao Evaluate Num 2.0
     4 rem Supported: iexplore.exe/firefox.exe
     5 set BROWSER_IMAGENAME=iexplore.exe
     6 if "%BROWSER_IMAGENAME%" equ "iexplore.exe" (
     7     set BROWSER_PATH_NAME=C:Program FilesInternet Exploreriexplore.exe
     8     set BROWSER_DEFAULT_PARAMS=
     9     set BEFORE_BROWSER_EXITS=CLEAR_IE
    10 ) else if "%BROWSER_IMAGENAME%" equ "firefox.exe" (
    11     set BROWSER_PATH_NAME=C:Program FilesMozilla Firefoxfirefox.exe
    12     set BROWSER_DEFAULT_PARAMS=-private-window
    13     set BEFORE_BROWSER_EXITS=CLEAR_FF
    14 ) else (
    15     echo It is an unsupported browser.
    16     goto :NORMAL_EXIT
    17 )
    18 set "CS_1=INFO: No tasks are running which match the specified criteria."
    19 echo 注意:接下来将自动强制结束所有进程%BROWSER_IMAGENAME%,如果存在进程%BROWSER_IMAGENAME%,可能会导致该程序无休止的启动任务。
    20 pause
    21 cls
    22 rem default
    23 set QUESTION_URL=https://zhidao.baidu.com/question/77631336.html
    24 set /p QUESTION_URL=Question url: 
    25 call :KILL_BROWSER
    26 for /l %%i in (0 0 0) do (
    27     echo Running...
    28     start "*_`" "%BROWSER_PATH_NAME%" %BROWSER_DEFAULT_PARAMS% %QUESTION_URL%
    29     cls
    30     echo Waiting...
    31     choice /c Ot /n /cs /t 6 /d O
    32     cls
    33     echo Cleaning up...
    34     call :%BEFORE_BROWSER_EXITS%
    35     cls
    36     echo Exiting...
    37     call :KILL_BROWSER
    38     cls
    39 )
    40 
    41 :CLEAR_IE
    42 rem Clear88571
    43 rundll32.exe inetcpl.cpl,ClearMyTracksByProcess Flags: 88571
    44 goto :EOF
    45 
    46 :KILL_BROWSER
    47 for /f "tokens=*" %%m in ('tasklist /nh /fi "imagename eq %BROWSER_IMAGENAME%"') do (
    48     if "%%m" neq "%CS_1%" (
    49         for /f "tokens=2" %%x in ("%%m") do (
    50             echo kill %%x
    51             taskkill /f /pid %%x
    52         )
    53     )
    54 )
    55 goto :EOF
    56 
    57 :NORMAL_EXIT
    58 pause
    59 exit

     

    附件1

  • 相关阅读:
    C库函数笔记
    曼彻斯特及差分曼彻斯特编码
    VS2008 由于应用程序配置不正确,应用程序未能启动。重新安装应用程序可能会纠正这个问题。
    刚子扯谈:酒装狗熊胆
    poj1410
    新游戏《真·方块无双》发布-穿越混世过险境,运筹方块化无双
    hdu4267 A Simple Problem with Integers
    【转载】变量的存储类型
    【转载】硬盘存储原理和内部结构
    【转载】让windows使用linux系统的命令
  • 原文地址:https://www.cnblogs.com/rms365/p/11015362.html
Copyright © 2020-2023  润新知