1
0
mirror of https://github.com/PurpleI2P/i2pdbrowser synced 2025-01-15 17:20:02 +00:00
i2pdbrowser/windows_prebuilt/src/StartI2PdBrowser.bat

44 lines
1.1 KiB
Batchfile
Raw Normal View History

2016-12-08 18:22:24 +03:00
@ECHO OFF
2018-03-20 23:25:22 +03:00
REM Copyright (c) 2013-2018, The PurpleI2P Project
2017-01-22 15:14:13 +03:00
REM This file is part of Purple i2pd project and licensed under BSD3
REM See full license text in LICENSE file at top of project tree
2018-03-20 23:25:22 +03:00
title Starting I2Pd Browser 1.2.7
2016-12-08 18:22:24 +03:00
set $pause=ping.exe 0.0.0.0 -n
2017-10-19 03:28:51 +03:00
set $cd=%CD%
2016-12-08 18:22:24 +03:00
ver| find "6." >nul && set $pause=timeout.exe /t
set fire=firefox.exe
set port=FirefoxPortable.exe
set i2pd=i2pd.exe
2017-10-19 03:28:51 +03:00
if not exist Firefox ( echo Firefox not found... Start building... && cd build && call build.cmd )
2016-12-08 18:22:24 +03:00
taskList|find /i "%port%">nul&&(taskkill /im "%port%" /t>nul)&&(%$pause% 2 >nul)
REM taskList|find /i "%fire%">nul&&(taskkill /im "%fire%" >nul)
taskList|find /i "%i2pd%">nul&&(goto runfox)||(goto starti2p)
:starti2p
2017-10-19 03:28:51 +03:00
cd i2pd
start "" "%i2pd%"
2016-12-08 18:22:24 +03:00
echo i2pd Browser starting
echo Please wait
echo -------------------------------------
for /L %%B in (0,1,35) do (call :EchoWithoutCrLf "." && %$pause% 2 >nul)
echo .
echo -------------------------------------
echo Welcome to I2P Network
2017-10-19 03:28:51 +03:00
cd %$cd%
2016-12-08 18:22:24 +03:00
:runfox
2017-10-19 03:28:51 +03:00
cd Firefox
start "" "%port%"
cd %$cd%
2016-12-08 18:22:24 +03:00
exit /b 0
:EchoWithoutCrLf
<nul set /p strTemp=%~1
exit /b 0