@echo off net session >nul 2>&1 rem if %errorLevel% == 0 ( goto go ) else ( goto elev ) :go echo Tinc install helper - specifcs echo --------------------------- echo What is your node name? set /P nodename=Node name: echo Do you want to upload your host file to the sinni vpn hostfile box? set /P answer=(y/n): if %answer% == y ( echo. ) else ( goto uphostno ) .\tools\curl -F "prefix=tincdrop" -F "path=/" -F "file=@.\hosts\%nodename%" https://metalgearsonic.de/FileUpload -k echo Done :uphostno echo Do you want to download all current host files? set /P answer=(y/n): if %answer% == y ( echo. ) else ( goto downhostno ) pushd .\hosts attrib +r +s %nodename% del /Q *.* attrib -r -s %nodename% echo Deleted all node files... Downloading new... ..\tools\curl --O "hosts.zip" -k "https://metalgearsonic.de/FileZip?path=\hosts&prefix=tinc" ..\tools\7z e -y hosts.zip del hosts.zip popd pause >nul :downhostno goto end :elev .\tools\elevate -c "%~f0" :end