-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathteamviewer-support.bat
55 lines (48 loc) · 1.43 KB
/
teamviewer-support.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
::
:: @file teamviewer-support.bat
:: @version v1.2
:: @description
:: A handy script for remote technical support using TeamViewer
:: Usage: Download & Run to start a TeamViewer remote connection
::
:: @url https://innovarew.appspot.com/
:: @author Innovarew <innovarew.solutions (at) gmail (dot) com>
:: @copyright (C) 2018 Innovarew Solutions. All Rights Reserved.
:: @license Proprietary and confidential
:: Unauthorized copying of this file, via any medium is strictly prohibited.
:: Contact us if you are interested in using our products and services.
::
:: Changelog:
::
:: [dd/mm/yyyy] [author]
:: [brief description]
::
:: 26/12/2018 innovarew
:: Initial version
::
@echo off
:: Prevent double-click execution
if %0 == "%~0" (
echo [*]
echo [*] [TeamViewer] Starting Remote Technical Support . . .
echo [*]
pause
)
set cwd=%~dp0
set tv_bat=%cwd%\teamviewer-support.bat
set tv_dir=%cwd%\TeamViewerPortable
set tv_file=%cwd%\TeamViewerPortable.zip
set tv_exe=%tv_dir%\TeamViewer.exe
set tv_url=https://dl.teamviewer.com/download/TeamViewerPortable.zip
cd %cwd%
:: Download TeamViewer
if exist "%tv_exe%" (
echo Found %tv_file%
) else (
ping dl.teamviewer.com -n 1
powershell -command "& { if (!(Test-Path %tv_dir%)) { Invoke-WebRequest %tv_url% -OutFile %tv_file%; Expand-Archive %tv_file% -DestinationPath %tv_dir%; } }"
)
:: make bat file readonly
attrib +r %tv_bat%
:: Start TeamViewer
%tv_exe%